Skip to content

Commit fb597f2

Browse files
cha5onRussell King
authored andcommitted
ARM: 8980/1: Allow either FLATMEM or SPARSEMEM on the multiplatform build
ARMv7 chips with LPAE can often benefit from SPARSEMEM, as portions of system memory can be located deep in the 36-bit address space. Allow FLATMEM or SPARSEMEM to be selectable at compile time; FLATMEM remains the default. This is based on Kevin's "[PATCH 3/3] ARM: Allow either FLATMEM or SPARSEMEM on the multi-v7 build" from [1] and shamelessly rips off his commit message text above. As Arnd pointed out at [2] there doesn't seem to be any reason to tie this specifically to ARMv7, so this has been changed to apply to all multiplatform kernels. The addition of this option does not change the defaults and a build with any defconfig will behave the same way as previously. The only effect this change has is to enable user to change "Memory model" selection in interactive kernel configuration (menuconfig, xconfig etc). [1] http://lists.infradead.org/pipermail/linux-arm-kernel/2014-September/286837.html [2] http://lists.infradead.org/pipermail/linux-arm-kernel/2014-October/298950.html [ rppt: added ARCH_SELECT_MEMORY_MODEL and updated the changelog ] Cc: Kevin Cernekee <[email protected]> Tested-by: Stephen Boyd <[email protected]> Signed-off-by: Gregory Fong <[email protected]> Signed-off-by: Doug Berger <[email protected]> Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: Mike Rapoport <[email protected]> Signed-off-by: Russell King <[email protected]>
1 parent 98f3f7e commit fb597f2

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

arch/arm/Kconfig

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,9 @@ choice
312312
config ARCH_MULTIPLATFORM
313313
bool "Allow multiple platforms to be selected"
314314
depends on MMU
315+
select ARCH_FLATMEM_ENABLE
316+
select ARCH_SPARSEMEM_ENABLE
317+
select ARCH_SELECT_MEMORY_MODEL
315318
select ARM_HAS_SG_CHAIN
316319
select ARM_PATCH_PHYS_VIRT
317320
select AUTO_ZRELADDR
@@ -1515,9 +1518,15 @@ config OABI_COMPAT
15151518
config ARCH_HAS_HOLES_MEMORYMODEL
15161519
bool
15171520

1521+
config ARCH_SELECT_MEMORY_MODEL
1522+
bool
1523+
1524+
config ARCH_FLATMEM_ENABLE
1525+
bool
1526+
15181527
config ARCH_SPARSEMEM_ENABLE
15191528
bool
1520-
select SPARSEMEM_STATIC
1529+
select SPARSEMEM_STATIC if SPARSEMEM
15211530

15221531
config HAVE_ARCH_PFN_VALID
15231532
def_bool ARCH_HAS_HOLES_MEMORYMODEL || !SPARSEMEM

0 commit comments

Comments
 (0)