Skip to content

Commit d3c5e32

Browse files
leoliu-ocopsiff
authored andcommitted
x86/cpu: Remove pointless evaluation of x86_coreid_bits
mainline inclusion from mainline-v6.6-rc1 commit 594957d category: other ------------------- [Only apply patch in zhaoxin.c ] cpuinfo_x86::x86_coreid_bits is only used by the AMD numa topology code. No point in evaluating it on non AMD systems. No functional change. Signed-off-by: Thomas Gleixner <[email protected]> Tested-by: Juergen Gross <[email protected]> Tested-by: Sohil Mehta <[email protected]> Tested-by: Michael Kelley <[email protected]> Tested-by: Peter Zijlstra (Intel) <[email protected]> Tested-by: Zhang Rui <[email protected]> Reviewed-by: Arjan van de Ven <[email protected]> Acked-by: Peter Zijlstra (Intel) <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: leoliu-oc <[email protected]>
1 parent 78c153a commit d3c5e32

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

arch/x86/kernel/cpu/zhaoxin.c

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -65,20 +65,6 @@ static void early_init_zhaoxin(struct cpuinfo_x86 *c)
6565
set_cpu_cap(c, X86_FEATURE_CONSTANT_TSC);
6666
set_cpu_cap(c, X86_FEATURE_NONSTOP_TSC);
6767
}
68-
69-
if (c->cpuid_level >= 0x00000001) {
70-
u32 eax, ebx, ecx, edx;
71-
72-
cpuid(0x00000001, &eax, &ebx, &ecx, &edx);
73-
/*
74-
* If HTT (EDX[28]) is set EBX[16:23] contain the number of
75-
* apicids which are reserved per package. Store the resulting
76-
* shift value for the package management code.
77-
*/
78-
if (edx & (1U << 28))
79-
c->x86_coreid_bits = get_count_order((ebx >> 16) & 0xff);
80-
}
81-
8268
}
8369

8470
static void init_zhaoxin(struct cpuinfo_x86 *c)

0 commit comments

Comments
 (0)