]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm/THP: don't use HPAGE_SHIFT in transparent hugepage code
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Wed, 19 Jun 2013 00:05:57 +0000 (10:05 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 19 Jun 2013 07:12:59 +0000 (17:12 +1000)
commitf030325fa01a450780f5357a3dcc2f50a506fb08
tree29371e864162e074dd5dd337a855997834e24e74
parent98856576cb5c871e51e0e9c3104c6980dee7bb45
mm/THP: don't use HPAGE_SHIFT in transparent hugepage code

For architectures like powerpc that support multiple explicit hugepage
sizes, HPAGE_SHIFT indicate the default explicit hugepage shift.  For THP
to work the hugepage size should be same as PMD_SIZE.  So use PMD_SHIFT
directly.  So move the define outside CONFIG_TRANSPARENT_HUGEPAGE #ifdef
because we want to use these defines in generic code with if
(pmd_trans_huge()) conditional.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: David Gibson <david@gibson.dropbear.id.au>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/huge_mm.h