summaryrefslogtreecommitdiff
path: root/arch/powerpc/include/asm/slice.h
diff options
context:
space:
mode:
authorChristophe Leroy <christophe.leroy@c-s.fr>2018-02-22 17:27:24 +0300
committerMichael Ellerman <mpe@ellerman.id.au>2018-03-06 01:21:23 +0300
commitdb3a528db41caaa6dfd4c64e9f5efb1c81a80467 (patch)
tree217c7aa6a24cb3d4b0900866090050aa3fdb8b0a /arch/powerpc/include/asm/slice.h
parenta3286f05bc5a5bc7fc73a9783ec89de78fcd07f8 (diff)
downloadlinux-db3a528db41caaa6dfd4c64e9f5efb1c81a80467.tar.xz
powerpc/mm/slice: Enhance for supporting PPC32
In preparation for the following patch which will fix an issue on the 8xx by re-using the 'slices', this patch enhances the 'slices' implementation to support 32 bits CPUs. On PPC32, the address space is limited to 4Gbytes, hence only the low slices will be used. The high slices use bitmaps. As bitmap functions are not prepared to handle bitmaps of size 0, this patch ensures that bitmap functions are called only when SLICE_NUM_HIGH is not nul. Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr> Reviewed-by: Nicholas Piggin <npiggin@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/include/asm/slice.h')
-rw-r--r--arch/powerpc/include/asm/slice.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/powerpc/include/asm/slice.h b/arch/powerpc/include/asm/slice.h
index 17c5a5d8c418..172711fadb1c 100644
--- a/arch/powerpc/include/asm/slice.h
+++ b/arch/powerpc/include/asm/slice.h
@@ -4,8 +4,10 @@
#ifdef CONFIG_PPC_BOOK3S_64
#include <asm/book3s/64/slice.h>
-#else
+#elif defined(CONFIG_PPC64)
#include <asm/nohash/64/slice.h>
+#elif defined(CONFIG_PPC_MMU_NOHASH)
+#include <asm/nohash/32/slice.h>
#endif
#ifdef CONFIG_PPC_MM_SLICES