Commit de6dfa19 authored by Kefeng Wang's avatar Kefeng Wang Committed by Zheng Zengkai
Browse files

mm: Move HOLES_IN_ZONE into mm

hulk inclusion
category: bugfix
bugzilla: 51781
CVE: NA

Reference: https://lore.kernel.org/linux-mm/20210417075946.181402-1-wangkefeng.wang@huawei.com/


--------------------------------

Move HOLES_IN_ZONE into mm/Kconfig, select it if architecture needs
this feature.

Signed-off-by: default avatarKefeng Wang <wangkefeng.wang@huawei.com>
Reviewed-by: default avatarJing Xiangfeng <jingxiangfeng@huawei.com>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
parent 22a79d02
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -184,6 +184,7 @@ config ARM64
	select HAVE_KPROBES
	select HAVE_KRETPROBES
	select HAVE_GENERIC_VDSO
	select HOLES_IN_ZONE
	select IOMMU_DMA if IOMMU_SUPPORT
	select IRQ_DOMAIN
	select IRQ_FORCED_THREADING
@@ -1039,9 +1040,6 @@ config NEED_PER_CPU_EMBED_FIRST_CHUNK
	def_bool y
	depends on NUMA

config HOLES_IN_ZONE
	def_bool y

source "kernel/Kconfig.hz"

config ARCH_SUPPORTS_DEBUG_PAGEALLOC
+1 −4
Original line number Diff line number Diff line
@@ -330,6 +330,7 @@ config NODES_SHIFT
config VIRTUAL_MEM_MAP
	bool "Virtual mem map"
	depends on !SPARSEMEM
	select HOLES_IN_ZONE
	default y
	help
	  Say Y to compile the kernel with support for a virtual mem map.
@@ -338,10 +339,6 @@ config VIRTUAL_MEM_MAP
	  require the DISCONTIGMEM option for your machine. If you are
	  unsure, say Y.

config HOLES_IN_ZONE
	bool
	default y if VIRTUAL_MEM_MAP

config HAVE_ARCH_EARLY_PFN_TO_NID
	def_bool NUMA && SPARSEMEM

+0 −3
Original line number Diff line number Diff line
@@ -1193,9 +1193,6 @@ config HAVE_PLAT_MEMCPY
config ISA_DMA_API
	bool

config HOLES_IN_ZONE
	bool

config SYS_SUPPORTS_RELOCATABLE
	bool
	help
+3 −0
Original line number Diff line number Diff line
@@ -129,6 +129,9 @@ config HAVE_FAST_GUP
	depends on MMU
	bool

config HOLES_IN_ZONE
	bool

# Don't discard allocated memory used to track "memory" and "reserved" memblocks
# after early boot, so it can still be used to test for validity of memory.
# Also, memblocks are updated with memory hot(un)plug.