lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 21 Jul 2016 09:13:39 +0200
From:	Vlastimil Babka <vbabka@...e.cz>
To:	David Rientjes <rientjes@...gle.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org, Michal Hocko <mhocko@...nel.org>,
	Mel Gorman <mgorman@...hsingularity.net>,
	Joonsoo Kim <iamjoonsoo.kim@....com>,
	Rik van Riel <riel@...hat.com>
Subject: Re: [PATCH 5/8] mm, page_alloc: make THP-specific decisions more
 generic

On 07/20/2016 01:10 AM, David Rientjes wrote:
> On Mon, 18 Jul 2016, Vlastimil Babka wrote:
>
>> This means we can further distinguish allocations that are costly order *and*
>> additionally include the __GFP_NORETRY flag. As it happens, GFP_TRANSHUGE
>> allocations do already fall into this category. This will also allow other
>> costly allocations with similar high-order benefit vs latency considerations to
>> use this semantic. Furthermore, we can distinguish THP allocations that should
>> try a bit harder (such as from khugepageed) by removing __GFP_NORETRY, as will
>> be done in the next patch.
>>
>> Signed-off-by: Vlastimil Babka <vbabka@...e.cz>
>> Acked-by: Michal Hocko <mhocko@...e.com>
>
> I think this is fine, but I would hope that we could check
> gfp_pfmemalloc_allowed() before compacting and failing even for costly
> orders when otherwise the first get_page_from_freelist() in the slowpath
> may have succeeded due to watermarks.

Hm ok, I will add it for the sake of avoiding goto nopage where 
previously it would have tried alloc without watermarks, as that would 
be unintended side-effect of the series... although I have some doubts 
about sanity of such scenarios (wants a costly order, can 
reclaim/compact but only with __GFP_NORETRY, yet is allowed to avoid 
watermarks?). Do you know about examples of such callers and think they 
do the right thing?

Thanks,
Vlastimil

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ