Skip to content

Commit 6937147

Browse files
committed
x86/cpufeatures: Add X86_FEATURE_AMD_HETEROGENEOUS_CORES
jira LE-4694 Rebuild_History Non-Buildable kernel-6.12.0-55.43.1.el10_0 commit-author Perry Yuan <perry.yuan@amd.com> commit 1ad4667 Empty-Commit: Cherry-Pick Conflicts during history rebuild. Will be included in final tarball splat. Ref for failed cherry-pick at: ciq/ciq_backports/kernel-6.12.0-55.43.1.el10_0/1ad46670.failed CPUID leaf 0x80000026 advertises core types with different efficiency rankings. Bit 30 indicates the heterogeneous core topology feature, if the bit set, it means not all instances at the current hierarchical level have the same core topology. This is described in the AMD64 Architecture Programmers Manual Volume 2 and 3, doc ID #25493 and #25494. Signed-off-by: Perry Yuan <perry.yuan@amd.com> Co-developed-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de> Link: https://lore.kernel.org/r/20241025171459.1093-3-mario.limonciello@amd.com (cherry picked from commit 1ad4667) Signed-off-by: Jonathan Maple <jmaple@ciq.com> # Conflicts: # arch/x86/include/asm/cpufeatures.h
1 parent fea346b commit 6937147

File tree

1 file changed

+60
-0
lines changed

1 file changed

+60
-0
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
x86/cpufeatures: Add X86_FEATURE_AMD_HETEROGENEOUS_CORES
2+
3+
jira LE-4694
4+
Rebuild_History Non-Buildable kernel-6.12.0-55.43.1.el10_0
5+
commit-author Perry Yuan <perry.yuan@amd.com>
6+
commit 1ad466706671436994ec7e71305f44692fed989a
7+
Empty-Commit: Cherry-Pick Conflicts during history rebuild.
8+
Will be included in final tarball splat. Ref for failed cherry-pick at:
9+
ciq/ciq_backports/kernel-6.12.0-55.43.1.el10_0/1ad46670.failed
10+
11+
CPUID leaf 0x80000026 advertises core types with different efficiency
12+
rankings.
13+
14+
Bit 30 indicates the heterogeneous core topology feature, if the bit
15+
set, it means not all instances at the current hierarchical level have
16+
the same core topology.
17+
18+
This is described in the AMD64 Architecture Programmers Manual Volume
19+
2 and 3, doc ID #25493 and #25494.
20+
21+
Signed-off-by: Perry Yuan <perry.yuan@amd.com>
22+
Co-developed-by: Mario Limonciello <mario.limonciello@amd.com>
23+
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
24+
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
25+
Link: https://lore.kernel.org/r/20241025171459.1093-3-mario.limonciello@amd.com
26+
(cherry picked from commit 1ad466706671436994ec7e71305f44692fed989a)
27+
Signed-off-by: Jonathan Maple <jmaple@ciq.com>
28+
29+
# Conflicts:
30+
# arch/x86/include/asm/cpufeatures.h
31+
diff --cc arch/x86/include/asm/cpufeatures.h
32+
index d96277dceabf,1216a0588ba8..000000000000
33+
--- a/arch/x86/include/asm/cpufeatures.h
34+
+++ b/arch/x86/include/asm/cpufeatures.h
35+
@@@ -476,7 -472,8 +476,12 @@@
36+
#define X86_FEATURE_BHI_CTRL (21*32+ 2) /* BHI_DIS_S HW control available */
37+
#define X86_FEATURE_CLEAR_BHB_HW (21*32+ 3) /* BHI_DIS_S HW control enabled */
38+
#define X86_FEATURE_CLEAR_BHB_LOOP_ON_VMEXIT (21*32+ 4) /* Clear branch history at vmexit using SW loop */
39+
++<<<<<<< HEAD
40+
+#define X86_FEATURE_FAST_CPPC (21*32 + 5) /* AMD Fast CPPC */
41+
++=======
42+
+ #define X86_FEATURE_AMD_FAST_CPPC (21*32 + 5) /* Fast CPPC */
43+
+ #define X86_FEATURE_AMD_HETEROGENEOUS_CORES (21*32 + 6) /* Heterogeneous Core Topology */
44+
++>>>>>>> 1ad466706671 (x86/cpufeatures: Add X86_FEATURE_AMD_HETEROGENEOUS_CORES)
45+
46+
/*
47+
* BUG word(s)
48+
* Unmerged path arch/x86/include/asm/cpufeatures.h
49+
diff --git a/arch/x86/kernel/cpu/scattered.c b/arch/x86/kernel/cpu/scattered.c
50+
index c84c30188fdf..2792fa29dbed 100644
51+
--- a/arch/x86/kernel/cpu/scattered.c
52+
+++ b/arch/x86/kernel/cpu/scattered.c
53+
@@ -52,6 +52,7 @@ static const struct cpuid_bit cpuid_bits[] = {
54+
{ X86_FEATURE_PERFMON_V2, CPUID_EAX, 0, 0x80000022, 0 },
55+
{ X86_FEATURE_AMD_LBR_V2, CPUID_EAX, 1, 0x80000022, 0 },
56+
{ X86_FEATURE_AMD_LBR_PMC_FREEZE, CPUID_EAX, 2, 0x80000022, 0 },
57+
+ { X86_FEATURE_AMD_HETEROGENEOUS_CORES, CPUID_EAX, 30, 0x80000026, 0 },
58+
{ 0, 0, 0, 0, 0 }
59+
};
60+

0 commit comments

Comments
 (0)