[PATCH] solve config broken: undefined reference to `online_page'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Andrew-san.

I made a small patch for compile error of 2.6.17(.1).
If CONFIG_HIGHMEM is not set and CONFIG_MEMORY_HOTPLUG is set on i386
box, the trouble occurs. Its trouble report is here.
http://marc.theaimsgroup.com/?t=115104987100003&r=1&w=2

At first, I wanted to send stable kernel which is 2.6.17.x.
But, Documentation/stable_kernel_rules.txt says that config
broken trouble is not acceptable for it. So, I would like to send
this to 2.6.18-rcX.

Please apply.

Thanks.

-----

Memory hotplug code of i386 adds memory to only highmem.
So, if CONFIG_HIGHMEM is not set, CONFIG_MEMORY_HOTPLUG shouldn't be
set. Otherwise, it causes compile error.

In addition, many architecture can't use memory hotplug feature yet.
So, I introduce CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG.

Signed-off-by: Yasunori Goto <[email protected]>

---
 arch/i386/Kconfig    |    3 +++
 arch/ia64/Kconfig    |    3 +++
 arch/powerpc/Kconfig |    3 +++
 arch/x86_64/Kconfig  |    2 ++
 mm/Kconfig           |    2 +-
 5 files changed, 12 insertions(+), 1 deletion(-)

Index: linux-2.6.17/mm/Kconfig
===================================================================
--- linux-2.6.17.orig/mm/Kconfig	2006-06-26 14:19:11.000000000 +0900
+++ linux-2.6.17/mm/Kconfig	2006-06-27 16:54:56.000000000 +0900
@@ -115,7 +115,7 @@ config SPARSEMEM_EXTREME
 # eventually, we can have this option just 'select SPARSEMEM'
 config MEMORY_HOTPLUG
 	bool "Allow for memory hot-add"
-	depends on SPARSEMEM && HOTPLUG && !SOFTWARE_SUSPEND
+	depends on SPARSEMEM && HOTPLUG && !SOFTWARE_SUSPEND && ARCH_ENABLE_MEMORY_HOTPLUG
 
 comment "Memory hotplug is currently incompatible with Software Suspend"
 	depends on SPARSEMEM && HOTPLUG && SOFTWARE_SUSPEND
Index: linux-2.6.17/arch/i386/Kconfig
===================================================================
--- linux-2.6.17.orig/arch/i386/Kconfig	2006-06-21 15:05:17.000000000 +0900
+++ linux-2.6.17/arch/i386/Kconfig	2006-06-27 16:44:01.000000000 +0900
@@ -762,6 +762,9 @@ config HOTPLUG_CPU
 	  enable suspend on SMP systems. CPUs can be controlled through
 	  /sys/devices/system/cpu.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+	def_bool y
+	depends on HIGHMEM
 
 endmenu
 
Index: linux-2.6.17/arch/ia64/Kconfig
===================================================================
--- linux-2.6.17.orig/arch/ia64/Kconfig	2006-06-21 15:05:18.000000000 +0900
+++ linux-2.6.17/arch/ia64/Kconfig	2006-06-27 16:52:51.000000000 +0900
@@ -270,6 +270,9 @@ config HOTPLUG_CPU
 	  can be controlled through /sys/devices/system/cpu/cpu#.
 	  Say N if you want to disable CPU hotplug.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+	def_bool y
+
 config SCHED_SMT
 	bool "SMT scheduler support"
 	depends on SMP
Index: linux-2.6.17/arch/powerpc/Kconfig
===================================================================
--- linux-2.6.17.orig/arch/powerpc/Kconfig	2006-06-21 15:05:29.000000000 +0900
+++ linux-2.6.17/arch/powerpc/Kconfig	2006-06-27 16:54:35.000000000 +0900
@@ -599,6 +599,9 @@ config HOTPLUG_CPU
 
 	  Say N if you are unsure.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+	def_bool y
+
 config KEXEC
 	bool "kexec system call (EXPERIMENTAL)"
 	depends on PPC_MULTIPLATFORM && EXPERIMENTAL
Index: linux-2.6.17/arch/x86_64/Kconfig
===================================================================
--- linux-2.6.17.orig/arch/x86_64/Kconfig	2006-06-21 15:05:40.000000000 +0900
+++ linux-2.6.17/arch/x86_64/Kconfig	2006-06-27 16:55:41.000000000 +0900
@@ -369,6 +369,8 @@ config HOTPLUG_CPU
 		can be controlled through /sys/devices/system/cpu/cpu#.
 		Say N if you want to disable CPU hotplug.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+	def_bool y
 
 config HPET_TIMER
 	bool

-- 
Yasunori Goto 


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux