x86: Add CPU vendor dependencies for MCE and legacy
v2 cover x86: Add CPU vendor dependencies for MCE and legacy
Intel-style MCE features and legacy AMD NUMA detection remain available when support for their CPU vendors is disabled. Add the corresponding CPU_SUP_* dependencies so that these options are only available when support for the relevant vendors is enabled.
---
Changes in v2:
- Drop patch 3, which removed PROCESSOR_SELECT's EXPERT dependency. Update the cover letter to reflect the reduced scope.
- Update the Intel MCE prompt and help text to mention Zhaoxin.
Link to v1: https://patch.msgid.link/20261031-processor_select_is_not_an_expert_feature-v1-0-6227bdbbe5a9@kernel.org
---
Vincent Mailhol (2):
x86/mce: Add CPU_SUP_* dependencies for Intel/Zhaoxin MCE features x86/numa: Add CPU_SUP_AMD dependency for legacy AMD NUMA
arch/x86/Kconfig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
---
base-commit: 7e1392a42ea288d70a266f6553fe06f57f8647ea
change-id: 20261030-processor_select_is_not_an_expert_feature-4f329d352ec3
Best regards,
Signature · 1 line
Vincent Mailhol <[email protected]>
PATCH v2 1/2 x86/mce: Add CPU_SUP_* dependencies for Intel/Zhaoxin MCE features
Intel-style MCE features are only used on Intel and Zhaoxin CPUs. Gate X86_MCE_INTEL on CPU_SUP_INTEL || CPU_SUP_ZHAOXIN.
Update the prompt and help text to mention both supported CPU vendors.
--- arch/x86/Kconfig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
arch/x86/Kconfig +3 -3
@@ -1158,10 +1158,10 @@ config X86_MCELOG_LEGACY config X86_MCE_INTEL def_bool y - prompt "Intel MCE features" - depends on X86_MCE && X86_LOCAL_APIC + prompt "Intel and Zhaoxin MCE features" + depends on X86_MCE && X86_LOCAL_APIC && (CPU_SUP_INTEL || CPU_SUP_ZHAOXIN) help - Additional support for intel specific MCE features such as + Additional support for Intel and Zhaoxin MCE features such as the thermal monitor. config X86_MCE_AMD
Signature · 1 line
2.56.1
Re: [PATCH v2 1/2] x86/mce: Add CPU_SUP_* dependencies for Intel/Zhaoxin MCE features
Quoted 5 lines · Vincent Mailhol
Intel-style MCE features are only used on Intel and Zhaoxin CPUs. Gate
X86_MCE_INTELonCPU_SUP_INTEL||CPU_SUP_ZHAOXIN.Update the prompt and help text to mention both supported CPU vendors.
Can we add a little bit more on why this change is needed? Is it mainly correcting user visible documentation or to reduce the built kernel size?
Quoted 11 lines
Signed-off-by Vincent Mailhol <[email protected]>--- arch/x86/Kconfig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)arch/x86/Kconfig +0
-0@@ -1158,10 +1158,10 @@ config X86_MCELOG_LEGACY
arch/x86/Kconfig config X86_MCELOG_LEGACY · line 1165
Quoted 10 lines
arch/x86/Kconfig +3
-3config X86_MCE_INTEL def_bool y - prompt "Intel MCE features" - depends on X86_MCE && X86_LOCAL_APIC + prompt "Intel and Zhaoxin MCE features" + depends on X86_MCE && X86_LOCAL_APIC && (CPU_SUP_INTEL || CPU_SUP_ZHAOXIN) help - Additional support for intel specific MCE features such as + Additional support for Intel and Zhaoxin MCE features such as the thermal monitor.
The thermal monitor is no longer part of X86_MCE_INTEL since commit 9223d0dccb8f ("thermal: Move therm_throt there from x86/mce"). If we are correcting this entry then can we remove the reference to the thermal monitor?
arch/x86/Kconfig config X86_MCELOG_LEGACY · line 1167
Quoted 3 lines
arch/x86/Kconfig +0
-0config X86_MCE_AMD
config X86_MCE_AMD
def_bool y prompt "AMD MCE features" depends on X86_MCE && X86_LOCAL_APIC help
The next entry looks slightly odd after the change. I was wondering why the AMD one doesn't need to depend on any CPU_SUP_* whereas the Intel one does?
PATCH v2 2/2 x86/numa: Add CPU_SUP_AMD dependency for legacy AMD NUMA
In reply to Vincent MailholThe legacy AMD NUMA probe reads topology from an Opteron northbridge.
It is only useful when AMD CPUs are supported, so gate it with CPU_SUP_AMD.
--- arch/x86/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/Kconfig +1 -1
@@ -1524,7 +1524,7 @@ config NUMA config AMD_NUMA def_bool y prompt "Old style AMD Opteron NUMA detection" - depends on X86_64 && NUMA && PCI + depends on X86_64 && NUMA && PCI && CPU_SUP_AMD help Enable AMD NUMA node topology detection. You should say Y here if you have a multi processor AMD system. This uses an old method to
Signature · 1 line
2.56.1