NR_CPUS configuration option wrong
Hi!
The configuration MAXSMP help text indicates it is used to enable configuration of number of CPUs. However, NR_CPUS depends on !MAXSMP.
arch/x86/Kconfig:
758 config NR_CPUS
759 int "Maximum number of CPUs" if SMP && !MAXSMP
Frank
Quoted 8 lines · On Thu, 20 May 2010 18:34:32 +0100 Frank A. Kingswood wrote:
Hi!
The configuration MAXSMP help text indicates it is used to enable configuration of number of CPUs. However,
NR_CPUSdepends on !MAXSMP.
arch/x86/Kconfig:
758 configNR_CPUS
759 int "Maximum number of CPUs" if SMP && !MAXSMP
That line depends on !MAXSMP. Then below there, we find:
default "4096" if MAXSMP
OK?
---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
Quoted 6 lines · Randy Dunlap
Quoted 4 lines · On Thu, 20 May 2010 18:34:32 +0100 Frank A. Kingswood wrote:
Hi!
The configuration MAXSMP help text indicates it is used to enable configuration of number of CPUs. However,
NR_CPUSdepends on !MAXSMP.
Quoted 7 lines
Quoted 3 lines
arch/x86/Kconfig:
758 configNR_CPUS
759 int "Maximum number of CPUs" if SMP && !MAXSMPThat line depends on !MAXSMP. Then below there, we find:
default "4096" if MAXSMP
Hah, weird.
I can see now it is possible to parse the MAXSMP help this way, but it was not obvious.
In menuconfig you see two questions:
[ ] Configure Maximum number of SMP Processors and NUMA Nodes
[8] Maximum number of CPUs
and setting the first one YES makes the second one go away.
Perhaps restating the help as "Set number of SMP processors and NUMA nodes to the maximum that the kernel supports" might help.
Thanks,
Frank
Quoted 12 lines · Frank A. Kingswood
Quoted 11 lines · Randy Dunlap
Quoted 8 lines · On Thu, 20 May 2010 18:34:32 +0100 Frank A. Kingswood wrote:
Hi!
The configuration MAXSMP help text indicates it is used to enable configuration of number of CPUs. However,
NR_CPUSdepends on !MAXSMP.
arch/x86/Kconfig:
758 configNR_CPUS
759 int "Maximum number of CPUs" if SMP && !MAXSMP
Quoted 7 lines
Quoted 3 lines
That line depends on !MAXSMP. Then below there, we find:
default "4096" if MAXSMP
Hah, weird.
I can see now it is possible to parse the MAXSMP help this way, but it was not obvious.
Ambiguity is fairly easy. :(
Quoted 9 lines
In menuconfig you see two questions:
[ ] Configure Maximum number of SMP Processors and NUMA Nodes
[8] Maximum number of CPUsand setting the first one YES makes the second one go away.
Perhaps restating the help as "Set number of SMP processors and NUMA nodes to the maximum that the kernel supports" might help.
Yes, that sounds better. Want to submit a patch for that?
Signature · 2 lines
~Randy *** Remember to use Documentation/SubmitChecklist when testing your code ***