mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
To: "Peter Zijlstra (Intel)" <peterz@infradead.org>
Cc: "Ravi V. Shankar" <ravi.v.shankar@intel.com>,
	Ricardo Neri <ricardo.neri@intel.com>,
	Ben Segall <bsegall@google.com>,
	Caleb Callaway <caleb.callaway@intel.com>,
	Chen Yu <yu.c.chen@intel.com>,
	Daniel Bristot de Oliveira <bristot@redhat.com>,
	Dietmar Eggemann <dietmar.eggemann@arm.com>,
	Len Brown <len.brown@intel.com>, Mel Gorman <mgorman@suse.de>,
	Steven Rostedt <rostedt@goodmis.org>,
	"Tim C . Chen" <tim.c.chen@intel.com>,
	Valentin Schneider <vschneid@redhat.com>,
	Vincent Guittot <vincent.guittot@linaro.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] x86/sched: Restore the SD_ASYM_PACKING flag in the DIE domain
Date: Mon, 11 Sep 2023 16:16:24 -0700	[thread overview]
Message-ID: <20230911231624.GA16338@ranerica-svr.sc.intel.com> (raw)
In-Reply-To: <20230815035747.11529-1-ricardo.neri-calderon@linux.intel.com>

On Mon, Aug 14, 2023 at 08:57:47PM -0700, Ricardo Neri wrote:
> Commit 8f2d6c41e5a6 ("x86/sched: Rewrite topology setup") dropped the
> SD_ASYM_PACKING flag in the DIE domain added in commit 044f0e27dec6
> ("x86/sched: Add the SD_ASYM_PACKING flag to the die domain of hybrid
> processors"). Restore it on hybrid processors.
> 
> The die-level domain does not depend on any build configuration and now
> x86_sched_itmt_flags() is always needed. Remove the build dependency on
> CONFIG_SCHED_[SMT|CLUSTER|MC].
> 
> Cc: Ben Segall <bsegall@google.com>
> Cc: Caleb Callaway <caleb.callaway@intel.com>
> Cc: Chen Yu <yu.c.chen@intel.com>
> Cc: Daniel Bristot de Oliveira <bristot@redhat.com>
> Cc: Dietmar Eggemann <dietmar.eggemann@arm.com>
> Cc: Len Brown <len.brown@intel.com>
> Cc: Mel Gorman <mgorman@suse.de>
> Cc: Steven Rostedt <rostedt@goodmis.org>
> Cc: Tim C. Chen <tim.c.chen@intel.com>
> Cc: Valentin Schneider <vschneid@redhat.com>
> Cc: Vincent Guittot <vincent.guittot@linaro.org>
> Cc: x86@kernel.org
> Cc: linux-kernel@vger.kernel.org
> Fixes: 8f2d6c41e5a6 ("x86/sched: Rewrite topology setup")
> Reviewed-by: Chen Yu <yu.c.chen@intel.com>
> Tested-by: Caleb Callaway <caleb.callaway@intel.com>
> Signed-off-by: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
> ---
>  arch/x86/kernel/smpboot.c | 10 +++++++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c
> index d7667a29acf3..944008c72754 100644
> --- a/arch/x86/kernel/smpboot.c
> +++ b/arch/x86/kernel/smpboot.c
> @@ -579,7 +579,6 @@ static bool match_llc(struct cpuinfo_x86 *c, struct cpuinfo_x86 *o)
>  }
>  
>  
> -#if defined(CONFIG_SCHED_SMT) || defined(CONFIG_SCHED_CLUSTER) || defined(CONFIG_SCHED_MC)
>  static inline int x86_sched_itmt_flags(void)
>  {
>  	return sysctl_sched_itmt_enabled ? SD_ASYM_PACKING : 0;
> @@ -603,7 +602,12 @@ static int x86_cluster_flags(void)
>  	return cpu_cluster_flags() | x86_sched_itmt_flags();
>  }
>  #endif
> -#endif
> +
> +static int x86_die_flags(void)
> +{
> +	return cpu_feature_enabled(X86_FEATURE_HYBRID_CPU) ?
> +	       x86_sched_itmt_flags() : 0;
> +}
>  
>  /*
>   * Set if a package/die has multiple NUMA nodes inside.
> @@ -640,7 +644,7 @@ static void __init build_sched_topology(void)
>  	 */
>  	if (!x86_has_numa_in_package) {
>  		x86_topology[i++] = (struct sched_domain_topology_level){
> -			cpu_cpu_mask, SD_INIT_NAME(DIE)
> +			cpu_cpu_mask, x86_die_flags, SD_INIT_NAME(DIE)
>  		};
>  	}
>  

Hi, just checking if there are any comments on this patch?

  reply	other threads:[~2023-09-12  2:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-15  3:57 Ricardo Neri
2023-09-11 23:16 ` Ricardo Neri [this message]
2023-09-12 11:45 ` Peter Zijlstra
2023-09-12 15:15 ` [tip: sched/urgent] " tip-bot2 for Ricardo Neri
2023-09-13 13:11 ` tip-bot2 for Ricardo Neri

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=20230911231624.GA16338@ranerica-svr.sc.intel.com \
    --to=ricardo.neri-calderon@linux.intel.com \
    --cc=bristot@redhat.com \
    --cc=bsegall@google.com \
    --cc=caleb.callaway@intel.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=peterz@infradead.org \
    --cc=ravi.v.shankar@intel.com \
    --cc=ricardo.neri@intel.com \
    --cc=rostedt@goodmis.org \
    --cc=tim.c.chen@intel.com \
    --cc=vincent.guittot@linaro.org \
    --cc=vschneid@redhat.com \
    --cc=x86@kernel.org \
    --cc=yu.c.chen@intel.com \
    /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

all inboxes | Powered by JetHome®