Thread (26 messages) 26 messages, 5 authors, 2013-05-17

[RFC PATCH v2 05/11] mm: thp: Correct the HPAGE_PMD_ORDER check.

From: Steve Capper <hidden>
Date: 2013-05-08 12:03:20
Also in: linux-arch, linux-mm

On Wed, May 08, 2013 at 03:44:17PM +0300, Kirill A. Shutemov wrote:
On Wed, May 08, 2013 at 10:52:37AM +0100, Steve Capper wrote:
quoted
All Transparent Huge Pages are allocated by the buddy allocator.

A compile time check is in place that fails when the order of a
transparent huge page is too large to be allocated by the buddy
allocator. Unfortunately that compile time check passes when:
HPAGE_PMD_ORDER == MAX_ORDER
( which is incorrect as the buddy allocator can only allocate
memory of order strictly less than MAX_ORDER. )
It looks confusing to me. Shouldn't we fix what MAX_ORDER means instead?
It confused me as I originally had 13 as the order and couldn't
allocate any 512MB THPs :-).

MAX_ORDER appears to be used quite a lot so I think it would be
safer to change the use case here rather than its meaning.

Cheers,
-- 
Steve
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help