From e0760d4d487beffc967be3ae2f38c56c9bf104ee Mon Sep 17 00:00:00 2001 From: Aurelien Jarno Date: Thu, 19 Apr 2018 11:13:03 +0100 Subject: [PATCH] MIPS: increase MAX_PHYSMEM_BITS on Loongson 3 only Commit c4617318 broke Loongson-2 support and maybe even more by increasing the value of MAX_PHYSMEM_BITS. At it is currently only needed on Loongson-3, define it conditionally. Note: this should be replace by upstream fix when available. Gbp-Pq: Topic features/mips Gbp-Pq: Name MIPS-increase-MAX-PHYSMEM-BITS-on-Loongson-3-only.patch --- arch/mips/include/asm/sparsemem.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/mips/include/asm/sparsemem.h b/arch/mips/include/asm/sparsemem.h index b0686ca3d8b..6201021de32 100644 --- a/arch/mips/include/asm/sparsemem.h +++ b/arch/mips/include/asm/sparsemem.h @@ -12,7 +12,12 @@ #else # define SECTION_SIZE_BITS 28 #endif -#define MAX_PHYSMEM_BITS 48 + +#if defined(CONFIG_CPU_LOONGSON3) +# define MAX_PHYSMEM_BITS 48 +#else +# define MAX_PHYSMEM_BITS 35 +#endif #endif /* CONFIG_SPARSEMEM */ #endif /* _MIPS_SPARSEMEM_H */ -- 2.30.2