Re: [PATCH RESEND] x86: Fix sibling map with NumaChip
From: Borislav Petkov
Date: Tue Mar 03 2015 - 11:30:59 EST
On Tue, Mar 03, 2015 at 11:18:13PM +0800, Daniel J Blueman wrote:
> @@ -180,11 +180,15 @@ static int __init numachip_probe(void)
>
> static void fixup_cpu_id(struct cpuinfo_x86 *c, int node)
> {
> -
> - if (c->phys_proc_id != node) {
> - c->phys_proc_id = node;
> - per_cpu(cpu_llc_id, smp_processor_id()) = node;
> - }
> + u64 val;
> + u32 nodes;
> +
> + per_cpu(cpu_llc_id, smp_processor_id()) = node;
> +
> + /* Account for nodes per socket in multi-core-module processors */
> + rdmsrl(MSR_FAM10H_NODE_ID, val);
You need to check a CPUID bit before accessing that MSR, see
amd_get_topology(). get_apic_id() in apic_numachip.c should be corrected
too.
Thanks.
--
Regards/Gruss,
Boris.
ECO tip #101: Trim your mails when you reply.
--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/