another NUMA build error
Hi,
I was just trying to reproduce that 'register_one_node' build error (and couldn't even with the supplied .config file; weird). Anyway, after I enabled CONFIG_NUMA (but not CONFIG_ACPI), I got the following error message. Seems that some config options should prevent this config from even being possible to create. Any ideas or suggestions?
This is still on 2.6.18-rc4-git1.
scripts/kconfig/conf -s arch/i386/Kconfig
CHK include/linux/version.h
CHK include/linux/utsrelease.h
CC arch/i386/kernel/asm-offsets.s
In file included from include/asm/mmzone.h:18,
from include/linux/mmzone.h:439,
from include/linux/gfp.h:4,
from include/linux/slab.h:14,
from include/linux/percpu.h:4,
from include/linux/rcupdate.h:41,
from include/linux/pid.h:4,
from include/linux/sched.h:70,
from include/linux/module.h:9,
from include/linux/crypto.h:20,
from arch/i386/kernel/asm-offsets.c:7:include/asm/srat.h:31:2: error: #error CONFIG_ACPI_SRAT not defined, and srat.h header has been included make[1]: *** [arch/i386/kernel/asm-offsets.s] Error 1
make: *** [prepare0] Error 2
config file is attached.
---
~Randy
Quoted 8 lines · On Thu, 24 Aug 2006 21:35:59 -0700 "Randy.Dunlap" <[email protected]> wrote:
Hi,
I was just trying to reproduce that 'register_one_node' build error (and couldn't even with the supplied .config file; weird). Anyway, after I enabledCONFIG_NUMA(but notCONFIG_ACPI), I got the following error message. Seems that some config options should prevent this config from even being possible to create. Any ideas or suggestions?
Hi, there are 2 ways.
1. allow only 2 configs for i386/NUMA
- CONFIG_NUMA + CONFIG_ACPI + CONFIG_ACPI_SRAT
- CONFIG_NUMA + CONFIG_X86_NUMAQ
2. allow this and fix include/asm-i386/mmzone.h
- CONFIG_NUMA + !CONFIG_ACP
Which is sane ?
-KameI
Quoted 13 lines · On Fri, 25 Aug 2006 14:43:50 +0900 KAMEZAWA Hiroyuki wrote:
Quoted 8 lines · On Thu, 24 Aug 2006 21:35:59 -0700 "Randy.Dunlap" <[email protected]> wrote:
Hi,
I was just trying to reproduce that 'register_one_node' build error (and couldn't even with the supplied .config file; weird). Anyway, after I enabledCONFIG_NUMA(but notCONFIG_ACPI), I got the following error message. Seems that some config options should prevent this config from even being possible to create. Any ideas or suggestions?Hi, there are 2 ways.
Quoted 7 lines
1. allow only 2 configs for i386/NUMA
-CONFIG_NUMA+CONFIG_ACPI+CONFIG_ACPI_SRAT
-CONFIG_NUMA+CONFIG_X86_NUMAQ
2. allow this and fixinclude/asm-i386/mmzone.h
-CONFIG_NUMA+ !CONFIG_ACPWhich is sane ?
I really can't answer that one. The people who care about NUMA would have to do that. It just shouldn't be possible to make a config with a build error like this.
OK, I prefer option 2 because it is more generic (not hardware- specific). Someone else can prefer option 1 because it is hardware-specific. :)
---
~Randy
Quoted 4 lines · On Fri, 25 Aug 2006 10:35:07 -0700 "Randy.Dunlap" <[email protected]> wrote:
OK, I prefer option 2 because it is more generic (not hardware- specific). Someone else can prefer option 1 because it is hardware-specific. :)
ok. patch is here. but people who know x86-numa should confirm this.
-Kame
--
compile fix for
In file included from include/asm/mmzone.h:18,
from include/linux/mmzone.h:439,
<snip>include/asm/srat.h:31:2: error: #error CONFIG_ACPI_SRAT not defined, and srat.h header has been included make[1]: *** [arch/i386/kernel/asm-offsets.s] Error 1
This can happen with CONFIG_NUMA && !CONFIG_ACPI && !CONFIG_X86_NUMAQ
include/asm-i386/mmzone.h | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-)
include/asm-i386/mmzone.h +1 -1
@@ -14,7 +14,7 @@ extern struct pglist_data *node_data[];#ifdef CONFIG_X86_NUMAQ #include <asm/numaq.h> -#else /* summit or generic arch */ +#elif defined(CONFIG_ACPI_SRAT )/* summit or generic arch */ #include <asm/srat.h> #endif
Quoted 31 lines · On Sat, 26 Aug 2006 03:28:34 +0900 KAMEZAWA Hiroyuki wrote:
Quoted 4 lines · On Fri, 25 Aug 2006 10:35:07 -0700 "Randy.Dunlap" <[email protected]> wrote:
OK, I prefer option 2 because it is more generic (not hardware- specific). Someone else can prefer option 1 because it is hardware-specific. :)
ok. patch is here. but people who know x86-numa should confirm this.
-Kame
--
compile fix forIn file included from
include/asm/mmzone.h:18,
frominclude/linux/mmzone.h:439,
<snip>include/asm/srat.h:31:2: error: #errorCONFIG_ACPI_SRATnot defined, andsrat.hheader has been included make[1]: *** [arch/i386/kernel/asm-offsets.s] Error 1This can happen with
CONFIG_NUMA&& !CONFIG_ACPI && !CONFIG_X86_NUMAQSigned-off-by KAMEZAWA Hiroyuki <[email protected]>include/asm-i386/mmzone.h | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-)Index:
linux-2.6.18-rc4/include/asm-i386/mmzone.h
===================================================================
include/asm-i386/mmzone.h extern struct pglist_data *node_data[]; · line 19
Quoted 7 lines
include/asm-i386/mmzone.h +1
-1@@ -14,7 +14,7 @@ extern struct pglist_data *node_data[];#ifdef CONFIG_X86_NUMAQ #include <asm/numaq.h> -#else /* summit or generic arch */ +#elif defined(CONFIG_ACPI_SRAT )/* summit or generic arch */ #include <asm/srat.h> #endif
That fixes mmzone.h but it still doesn't produce kernel that will build without error:
arch/i386/mm/discontig.c: In function ‘zone_sizes_init’:arch/i386/mm/discontig.c:388: warning: implicit declaration of function ‘get_zholes_size’ arch/i386/mm/discontig.c:388: warning: assignment makes pointer from integer without a cast
and:
LD .tmp_vmlinux1arch/i386/mm/built-in.o: In function `zone_sizes_init':
(.init.text+0xd05): undefined reference to `get_zholes_size'
make: *** [.tmp_vmlinux1] Error 1
Same .config as in previous email.
---
~Randy
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 35 lines · On Fri, 25 Aug 2006 15:44:58 -0700 Keith Mannthey wrote:
Quoted 21 lines · Randy.Dunlap
Quoted 19 lines · On Fri, 25 Aug 2006 14:43:50 +0900 KAMEZAWA Hiroyuki wrote:
Quoted 8 lines · On Thu, 24 Aug 2006 21:35:59 -0700 "Randy.Dunlap" <[email protected]> wrote:
Hi,
I was just trying to reproduce that 'register_one_node' build error (and couldn't even with the supplied .config file; weird). Anyway, after I enabledCONFIG_NUMA(but notCONFIG_ACPI), I got the following error message. Seems that some config options should prevent this config from even being possible to create. Any ideas or suggestions?Hi, there are 2 ways.
1. allow only 2 configs for i386/NUMA
-CONFIG_NUMA+CONFIG_ACPI+CONFIG_ACPI_SRAT
-CONFIG_NUMA+CONFIG_X86_NUMAQ
2. allow this and fixinclude/asm-i386/mmzone.h
-CONFIG_NUMA+ !CONFIG_ACPQuoted 5 lines
Quoted 1 line
Which is sane ?
I really can't answer that one. The people who care about NUMA would have to do that. It just shouldn't be possible to make a config with a build error like this.
I thought there was a patch fix a while ago to fix this build issue. If you want to anything that includes the SUMMIT sub arch you need
CONFIG_ACPI_SRAT.Option 1 is a good solution as only NUMAQ and
ACPI_SRAThave tables that are used to setup NUMA in the kernel.
Quoted 6 lines
Quoted 3 lines
OK, I prefer option 2 because it is more generic (not hardware- specific). Someone else can prefer option 1 because it is hardware-specific. :)
I guess I am that other person. Really you only want/need NUMA if you have
ACPI_SRAT(Summit) or NUMAQ.
That's fine. Any fix is OK with me, as long as a .config won't generate a build error.
---
~Randy
Quoted 11 lines · On Fri, 25 Aug 2006 16:01:15 -0700 "Randy.Dunlap" <[email protected]> wrote:
Quoted 11 lines
I thought there was a patch fix a while ago to fix this build issue. If you want to anything that includes the SUMMIT sub arch you need
CONFIG_ACPI_SRAT.Option 1 is a good solution as only NUMAQ and
ACPI_SRAThave tables that are used to setup NUMA in the kernel.Quoted 3 lines
OK, I prefer option 2 because it is more generic (not hardware- specific). Someone else can prefer option 1 because it is hardware-specific. :)
Quoted 6 lines
Quoted 2 lines
I guess I am that other person. Really you only want/need NUMA if you have
ACPI_SRAT(Summit) or NUMAQ.That's fine. Any fix is OK with me, as long as a .config won't generate a build error.
Hmm... is this the way to go ?
Keith-san, please ack if Okay.
-Kame
--
When we select NUMA with i386, the system is only X86_NUMAQ or using ACPI.
arch/i386/Kconfig +3 -1
@@ -142,6 +142,7 @@ config X86_SUMMIT In particular, it is needed for the x440. If you don't have one of these computers, you should say N here. + If you want to build NUMA kernel, you have to select ACPI config X86_BIGSMP bool "Support for other sub-arch SMP systems with more than 8 CPUs"
@@ -169,6 +170,7 @@ config X86_GENERICARCH help This option compiles in the Summit, bigsmp, ES7000, default subarchitectures. It is intended for a generic binary kernel. + if you want NUMA kernel, select ACPI. we need SRAT for build NUMA config X86_ES7000 bool "Support for Unisys ES7000 IA32 series"
@@ -542,7 +544,7 @@ config X86_PAE # Common NUMA Features config NUMA bool "Numa Memory Allocation and Scheduler Support" - depends on SMP && HIGHMEM64G && (X86_NUMAQ || X86_GENERICARCH || (X86_SUMMIT && ACPI)) + depends on SMP && HIGHMEM64G && (X86_NUMAQ || (X86_SUMMIT || X86_GENERICARCH) && ACPI) default n if X86_PC default y if (X86_NUMAQ || X86_SUMMIT)
Quoted 3 lines
Quoted 1 line
Hmm... is this the way to go ?
Keith-san, please ack if Okay.
Works for me. No build errors. Thanks.
There are a couple of typos noted below that could be fixed up.
Quoted 10 lines
--
When we select NUMA with i386, the system is onlyX86_NUMAQor using ACPI.Signed-off-by KAMEZAWA Hiroyuki <[email protected]>Index: linux-2.6.18-rc4/arch/i386/Kconfig
===================================================================
arch/i386/Kconfig config X86_SUMMIT · line 145
Quoted 4 lines
arch/i386/Kconfig +1
-0@@ -142,6 +142,7 @@ config X86_SUMMIT In particular, it is needed for the x440. If you don't have one of these computers, you should say N here. + If you want to build NUMA kernel, you have to select ACPI
end with '.'
arch/i386/Kconfig config X86_GENERICARCH · line 173
Quoted 8 lines
arch/i386/Kconfig +1
-0config X86_BIGSMP bool "Support for other sub-arch SMP systems with more than 8 CPUs"@@ -169,6 +170,7 @@ config X86_GENERICARCH help This option compiles in the Summit, bigsmp, ES7000, default subarchitectures. It is intended for a generic binary kernel. + if you want NUMA kernel, select ACPI. we need SRAT for build NUMA
If you want a NUMA kernel, enable ACPI. We need SRAT to build NUMA.
arch/i386/Kconfig config X86_PAE · line 549
Quoted 11 lines
arch/i386/Kconfig +1
-1config X86_ES7000 bool "Support for Unisys ES7000 IA32 series"@@ -542,7 +544,7 @@ config X86_PAE # Common NUMA Features config NUMA bool "Numa Memory Allocation and Scheduler Support" - depends on SMP && HIGHMEM64G && (X86_NUMAQ || X86_GENERICARCH || (X86_SUMMIT && ACPI)) + depends on SMP && HIGHMEM64G && (X86_NUMAQ || (X86_SUMMIT || X86_GENERICARCH) && ACPI) default n if X86_PC default y if (X86_NUMAQ || X86_SUMMIT)
---
~Randy