public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Zhang, Rui" <rui.zhang@intel.com>
To: "Hansen, Dave" <dave.hansen@intel.com>,
	"bp@alien8.de" <bp@alien8.de>, "x86@kernel.org" <x86@kernel.org>,
	"peterz@infradead.org" <peterz@infradead.org>,
	"hpa@zytor.com" <hpa@zytor.com>,
	"mingo@redhat.com" <mingo@redhat.com>,
	"tglx@linutronix.de" <tglx@linutronix.de>,
	"paulmck@kernel.org" <paulmck@kernel.org>,
	"longman@redhat.com" <longman@redhat.com>,
	"Tang, Feng" <feng.tang@intel.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: "dave.hansen@linux.intel.com" <dave.hansen@linux.intel.com>
Subject: Re: [PATCH] x86/tsc: Use topology_max_packages() to get package number
Date: Sun, 17 Mar 2024 12:00:26 +0000	[thread overview]
Message-ID: <f9da97d86e5599edca74fa859053ba9caf2b4d9c.camel@intel.com> (raw)
In-Reply-To: <ce02f1a8-870f-41bc-8650-4bd6103f9637@intel.com>

On Fri, 2024-03-15 at 10:58 -0700, Dave Hansen wrote:
> On 3/15/24 04:26, Feng Tang wrote:
> > Thomas' recent patchset of refactoring x86 topology code introduces
> > topology_max_package(), 

s/topology_max_package/topology_max_packages

And topology_max_packages() is not new. The patch set actually
improves/fixes it.


> 
> I also did a big *gulp* when I saw this:
> 
>         #define topology_max_packages() (__max_logical_packages)
> 
> and:
> 
> >         /*
> >          * Today neither Intel nor AMD support heterogeneous
> > systems so
> >          * extrapolate the boot cpu's data to all packages.
> >          */
> >         ncpus = cpu_data(0).booted_cores *
> > topology_max_smt_threads();
> >         __max_logical_packages = DIV_ROUND_UP(total_cpus, ncpus);
> 
> Because Intel obviously has heterogeneous systems today.
> 
Dave, I think you were checking the old code.
Please refer to commit 090610ba704a ("x86/cpu/topology: Use topology
bitmaps for sizing"), which is just merged in this merge window.

thanks,
rui

  parent reply	other threads:[~2024-03-17 12:00 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-15 11:26 [PATCH] x86/tsc: Use topology_max_packages() to get package number Feng Tang
2024-03-15 17:58 ` Dave Hansen
2024-03-15 20:51   ` Thomas Gleixner
2024-03-18  1:03     ` Feng Tang
2024-03-17 12:00   ` Zhang, Rui [this message]
2024-03-18  1:18     ` Feng Tang
2024-03-18 15:08     ` Dave Hansen
2024-03-18  1:16   ` Feng Tang
2024-03-18  2:03 ` Waiman Long
2024-03-18  1:57   ` Feng Tang
2024-03-18 16:35 ` Dave Hansen
2024-03-19  2:11   ` Feng Tang

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=f9da97d86e5599edca74fa859053ba9caf2b4d9c.camel@intel.com \
    --to=rui.zhang@intel.com \
    --cc=bp@alien8.de \
    --cc=dave.hansen@intel.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=feng.tang@intel.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=longman@redhat.com \
    --cc=mingo@redhat.com \
    --cc=paulmck@kernel.org \
    --cc=peterz@infradead.org \
    --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