diff --git a/arch/x86/kernel/cpu/hygon.c b/arch/x86/kernel/cpu/hygon.c index 1e7b5466c963527b53059426d2533c837977b4f0..a52abe29155e88a9deaab723bbcd700a9e4f3fee 100644 --- a/arch/x86/kernel/cpu/hygon.c +++ b/arch/x86/kernel/cpu/hygon.c @@ -150,8 +150,15 @@ static void srat_detect_node(struct cpuinfo_x86 *c) unsigned int apicid = c->apicid; node = numa_cpu_node(cpu); - if (node == NUMA_NO_NODE) - node = per_cpu(cpu_llc_id, cpu); + if (node == NUMA_NO_NODE) { + if (c->x86_model >= 0x4 && c->x86_model <= 0x8) { + node = cpu_to_node(cpu); + numa_set_node(cpu, node); + return; + } else { + node = per_cpu(cpu_llc_id, cpu); + } + } /* * On multi-fabric platform (e.g. Numascale NumaChip) a