]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/mm/hugetlb: initialize the pagetable cache correctly for hugetlb
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Fri, 30 Mar 2018 12:04:08 +0000 (17:34 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 4 Apr 2018 06:58:53 +0000 (16:58 +1000)
commitcc6fcf7e7400727240e2aab72a6c60371a0203d3
tree7c4d5ba83317139477516e2e21bd0ad7c55e23d1
parent97f8535312b335fad45f23d10406082747219c6a
powerpc/mm/hugetlb: initialize the pagetable cache correctly for hugetlb

With 64k page size, we have hugetlb pte entries at the pmd and pud level for
book3s64. We don't need to create a separate page table cache for that. With 4k
we need to make sure hugepd page table cache for 16M is placed at PUD level
and 16G at the PGD level.

Simplify all these by not using HUGEPD_PD_SHIFT which is confusing for book3s64.

Without this patch, with 64k page size we create pagetable caches with shift
value 10 and 7 which are not used at all.

Fixes: 0c881bb87f7e ("powerpc: Reduce the PTE_INDEX_SIZE")
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/mm/hugetlbpage.c