Re: mm: Do not drain pagevecs for mlockall(MCL_FUTURE)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 7, 2011 at 7:45 PM, David Rientjes <rientjes@xxxxxxxxxx> wrote:
> On Fri, 7 Oct 2011, Christoph Lameter wrote:
>> -     lru_add_drain_all();    /* flush pagevec */
>> +     if (flags & MCL_CURRENT)
>> +             lru_add_drain_all();    /* flush pagevec */
>
> I understand the intention of lru_add_drain_all() to try to avoid a
> later failure when moving to the unevictable list and why flushing it's
> necessary for MCL_FUTURE, but I think this should be written
>
>        if (!(flags & MCL_FUTURE))
>                ...
>
> since flags may be extended sometime in the future.

When flags == (MCL_CURRENT | MCL_FUTURE), we do want to flush the
pagevecs as in the straight MCL_CURRENT case, so I think Christoph's
version is the correct one.

-- 
Michel "Walken" Lespinasse
A program is never fully debugged until the last user dies.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]