Skip to contentSkip to conversation

use range for NR_CPUS

PATCH In review Adrian Bunk 2 participants 3 messages Jan 9, 2004

Subsystems (7)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 use range for NR_CPUS

The 2.6 Kconfig language allows to set the range for integer questions.

The patch below adds a range line on all architectures that have a NR_CPUS question except ia64.

The help text on ia64 didn't suggest any values. Could someone tell the correct values for ia64 (and if it's only a minimum value of 2)?

diffstat output:

 arch/alpha/Kconfig   |    1 +
 arch/i386/Kconfig    |    1 +
 arch/mips/Kconfig    |    1 +
 arch/parisc/Kconfig  |    1 +
 arch/ppc/Kconfig     |    1 +
 arch/ppc64/Kconfig   |    1 +
 arch/s390/Kconfig    |    2 ++
 arch/sh/Kconfig      |    1 +
 arch/sparc/Kconfig   |    1 +
 arch/sparc64/Kconfig |    1 +
 arch/um/Kconfig      |    1 +
 arch/x86_64/Kconfig  |    1 +
 12 files changed, 13 insertions(+)

cu
Adrian

arch/sparc64/Kconfig renamed from arch/sparc64/Kconfig.old +1 -0
@@ -128,6 +128,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-64)"
+	range 2 64
 	depends on SMP
 	default "64"
 
arch/i386/Kconfig renamed from arch/i386/Kconfig.old +1 -0
@@ -495,6 +495,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-255)"
+	range 2 255
 	depends on SMP
 	default "32" if X86_NUMAQ || X86_SUMMIT || X86_BIGSMP || X86_ES7000
 	default "8"
arch/sparc/Kconfig renamed from arch/sparc/Kconfig.old +1 -0
@@ -112,6 +112,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP
 	default "32"
 
arch/ppc/Kconfig renamed from arch/ppc/Kconfig.old +1 -0
@@ -681,6 +681,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP
 	default "4"
 
arch/um/Kconfig renamed from arch/um/Kconfig.old +1 -0
@@ -128,6 +128,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP
 	default "32"
 
arch/mips/Kconfig renamed from arch/mips/Kconfig.old +1 -0
@@ -981,6 +981,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP
 	default "32"
 	help
arch/sh/Kconfig renamed from arch/sh/Kconfig.old +1 -0
@@ -467,6 +467,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP
 	default "2"
 	help
arch/alpha/Kconfig renamed from arch/alpha/Kconfig.old +1 -0
@@ -509,6 +509,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-64)"
+	range 2 64
 	depends on SMP
 	default "64"
 
arch/ppc64/Kconfig renamed from arch/ppc64/Kconfig.old +1 -0
@@ -97,6 +97,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-128)"
+	range 2 128
 	depends on SMP
 	default "32"
 
arch/parisc/Kconfig renamed from arch/parisc/Kconfig.old +1 -0
@@ -154,6 +154,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP
 	default "32"
 
arch/x86_64/Kconfig renamed from arch/x86_64/Kconfig.old +1 -0
@@ -233,6 +233,7 @@
 # to use clustered mode or whatever your big iron needs
 config NR_CPUS
 	int "Maximum number of CPUs (2-8)"
+	range 2 8
 	depends on SMP
 	default "8"
 	help
arch/s390/Kconfig renamed from arch/s390/Kconfig.old +2 -0
@@ -97,6 +97,7 @@
 
 config NR_CPUS
 	int "Maximum number of CPUs (2-32)"
+	range 2 32
 	depends on SMP && ARCH_S390X = 'n'
 	default "32"
 	help
@@ -109,6 +110,7 @@
 	
 config NR_CPUS
 	int "Maximum number of CPUs (2-64)"
+	range 2 64
 	depends on SMP && ARCH_S390X
 	default "64"
 	help
#1 lore raw
Quoted 2 lines

The help text on ia64 didn't suggest any values. Could someone tell the correct values for ia64 (and if it's only a minimum value of 2)?

It keeps moving. We've announced experimental versions up to 512 CPUs, I believe. We being SGI, and our SN product, which uses ia64 arch. So I guess you can put that in.

Signature · 3 lines
                          I won't rest till it's the best ...
                          Programmer, Linux Scalability
                          Paul Jackson <[email protected]> 1.650.933.1373
#2 lore raw

PATCH 1/1 ia64: use range for NR_CPUS

Quoted 6 lines · Paul Jackson
Quoted 2 lines

The help text on ia64 didn't suggest any values. Could someone tell the correct values for ia64 (and if it's only a minimum value of 2)?

It keeps moving. We've announced experimental versions up to 512 CPUs, I believe. We being SGI, and our SN product, which uses ia64 arch. So I guess you can put that in.

Thanks for this information.

The patch to use "range" for NR_CPUS on ia64 is below.

cu
Adrian

arch/ia64/Kconfig renamed from arch/ia64/Kconfig.old +2 -1
@@ -411,7 +411,8 @@
 	  support" (CONFIG_PROC_FS) is enabled, too.
 
 config NR_CPUS
-	int "Maximum number of CPUs"
+	int "Maximum number of CPUs (2-512)"
+	range 2 512
 	depends on SMP
 	default "64"
 	help