summaryrefslogtreecommitdiffstats
path: root/arch/xtensa/mm/mmu.c
diff options
context:
space:
mode:
authorMike Rapoport <rppt@linux.ibm.com>2019-11-05 15:33:20 +0100
committerMax Filippov <jcmvbkbc@gmail.com>2019-11-26 20:33:39 +0100
commitf5ee2567921dec4f489c16d4fe22c3a7222d0ce6 (patch)
tree54a6a21fad933163b9b486439d852c33b9438a1a /arch/xtensa/mm/mmu.c
parentxtensa: mm: fix PMD folding implementation (diff)
downloadlinux-f5ee2567921dec4f489c16d4fe22c3a7222d0ce6.tar.xz
linux-f5ee2567921dec4f489c16d4fe22c3a7222d0ce6.zip
xtensa: get rid of __ARCH_USE_5LEVEL_HACK
xtensa has 2-level page tables and already uses pgtable-nopmd for page table folding. Add walks of p4d level where appropriate and drop usage of __ARCH_USE_5LEVEL_HACK. Signed-off-by: Mike Rapoport <rppt@linux.ibm.com> Message-Id: <1572964400-16542-3-git-send-email-rppt@kernel.org> Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> [fix up arch/xtensa/include/asm/fixmap.h and arch/xtensa/mm/tlb.c]
Diffstat (limited to 'arch/xtensa/mm/mmu.c')
-rw-r--r--arch/xtensa/mm/mmu.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/xtensa/mm/mmu.c b/arch/xtensa/mm/mmu.c
index 018dda2c6a91..37e478a27877 100644
--- a/arch/xtensa/mm/mmu.c
+++ b/arch/xtensa/mm/mmu.c
@@ -22,7 +22,8 @@
static void * __init init_pmd(unsigned long vaddr, unsigned long n_pages)
{
pgd_t *pgd = pgd_offset_k(vaddr);
- pud_t *pud = pud_offset(pgd, vaddr);
+ p4d_t *p4d = p4d_offset(pgd, vaddr);
+ pud_t *pud = pud_offset(p4d, vaddr);
pmd_t *pmd = pmd_offset(pud, vaddr);
pte_t *pte;
unsigned long i;