aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86_64/kernel/setup.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86_64/kernel/setup.c b/arch/x86_64/kernel/setup.c
index ad3b7fc24a05..49f285871df5 100644
--- a/arch/x86_64/kernel/setup.c
+++ b/arch/x86_64/kernel/setup.c
@@ -846,7 +846,7 @@ static void __init amd_detect_cmp(struct cpuinfo_x86 *c)
846 unsigned bits; 846 unsigned bits;
847#ifdef CONFIG_NUMA 847#ifdef CONFIG_NUMA
848 int node = 0; 848 int node = 0;
849 unsigned apicid = phys_proc_id[cpu]; 849 unsigned apicid = hard_smp_processor_id();
850#endif 850#endif
851 851
852 bits = 0; 852 bits = 0;
@@ -856,7 +856,7 @@ static void __init amd_detect_cmp(struct cpuinfo_x86 *c)
856 /* Low order bits define the core id (index of core in socket) */ 856 /* Low order bits define the core id (index of core in socket) */
857 cpu_core_id[cpu] = phys_proc_id[cpu] & ((1 << bits)-1); 857 cpu_core_id[cpu] = phys_proc_id[cpu] & ((1 << bits)-1);
858 /* Convert the APIC ID into the socket ID */ 858 /* Convert the APIC ID into the socket ID */
859 phys_proc_id[cpu] >>= bits; 859 phys_proc_id[cpu] = phys_pkg_id(bits);
860 860
861#ifdef CONFIG_NUMA 861#ifdef CONFIG_NUMA
862 node = phys_proc_id[cpu]; 862 node = phys_proc_id[cpu];