powerpc/8xx: mmu_virtual_psize incorrect for 16k pages
authorLEROY Christophe <christophe.leroy@c-s.fr>
Fri, 17 Apr 2015 16:37:17 +0000 (18:37 +0200)
committerScott Wood <scottwood@freescale.com>
Wed, 3 Jun 2015 02:37:23 +0000 (21:37 -0500)
mmu_virtual_psize shall be set to MMU_PAGE_16K when 16k pages have
been selected

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Scott Wood <scottwood@freescale.com>
arch/powerpc/include/asm/mmu-8xx.h

index 986b9e1e1044f62a9b66454ae71d9a69a3bbd366..d41200c01d8547b3e80c2bfb420127d6a688342a 100644 (file)
@@ -145,7 +145,14 @@ typedef struct {
 } mm_context_t;
 #endif /* !__ASSEMBLY__ */
 
+#if (PAGE_SHIFT == 12)
 #define mmu_virtual_psize      MMU_PAGE_4K
+#elif (PAGE_SHIFT == 14)
+#define mmu_virtual_psize      MMU_PAGE_16K
+#else
+#error "Unsupported PAGE_SIZE"
+#endif
+
 #define mmu_linear_psize       MMU_PAGE_8M
 
 #endif /* _ASM_POWERPC_MMU_8XX_H_ */