public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: Daniel J Blueman <daniel@numascale.com>
Cc: Ingo Molnar <mingo@redhat.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	"H. Peter Anvin" <hpa@zytor.com>,
	x86@kernel.org, linux-kernel@vger.kernel.org,
	Steffen Persvold <sp@numascale.com>
Subject: Re: [PATCH RESEND] x86: Fix sibling map with NumaChip
Date: Tue, 3 Mar 2015 17:29:43 +0100	[thread overview]
Message-ID: <20150303162943.GA3673@pd.tnic> (raw)
In-Reply-To: <1425395893-21157-1-git-send-email-daniel@numascale.com>

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.
--

      reply	other threads:[~2015-03-03 16:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-03 15:18 [PATCH RESEND] x86: Fix sibling map with NumaChip Daniel J Blueman
2015-03-03 16:29 ` Borislav Petkov [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150303162943.GA3673@pd.tnic \
    --to=bp@alien8.de \
    --cc=daniel@numascale.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=sp@numascale.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox