mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Chen Yu <yu.c.chen@intel.com>
To: Shrikanth Hegde <sshegde@linux.vnet.ibm.com>
Cc: <mingo@redhat.com>, <peterz@infradead.org>,
	<vincent.guittot@linaro.org>, <dietmar.eggemann@arm.com>,
	<vschneid@redhat.com>, <linux-kernel@vger.kernel.org>,
	<ionela.voinescu@arm.com>, <quentin.perret@arm.com>,
	<srikar@linux.vnet.ibm.com>, <mgorman@techsingularity.net>,
	<mingo@kernel.org>
Subject: Re: [PATCH] sched/topology: remove sysctl_sched_energy_aware depending on the architecture
Date: Wed, 30 Aug 2023 21:16:57 +0800	[thread overview]
Message-ID: <ZO9BSaGpF5lIAjzy@chenyu5-mobl2> (raw)
In-Reply-To: <20230829065040.920629-1-sshegde@linux.vnet.ibm.com>

Hi Shrikanth,

On 2023-08-29 at 12:20:40 +0530, Shrikanth Hegde wrote:
> Currently sysctl_sched_energy_aware doesn't alter the said behaviour on
> some of the architectures. IIUC its meant to either force rebuild the
> perf domains or cleanup the perf domains by echoing 1 or 0 respectively.
> 
> perf domains are not built when there is SMT, or when there is no
> Asymmetric CPU topologies or when there is no frequency invariance.
> Since such cases EAS is not set and perf domains are not built. By
> changing the values of sysctl_sched_energy_aware, its not possible to
> force build the perf domains. Hence remove this sysctl on such platforms
> that dont support it at boot. Some of the settings can be changed later
> such as smt_active by offlining the CPU's, In those cases
> build_perf_domains returns true, in that case re-enable the sysctl.
> 
> Signed-off-by: Shrikanth Hegde <sshegde@linux.vnet.ibm.com>
>

[snip...]
 
> @@ -380,15 +400,11 @@ static bool build_perf_domains(const struct cpumask *cpu_map)
>  	struct cpufreq_policy *policy;
>  	struct cpufreq_governor *gov;
> 
> -	if (!sysctl_sched_energy_aware)
> -		goto free;
> -

I tried to ramp up the EAS and maybe I overlooked it, why do we remove above
check? If the system boots with EAS enabled and sysctl_sched_energy_aware
set to 1, then the user wants to disable EAS then changing sysctl_sched_energy_aware
to 0. Without above check, how could the perf domain be freed?

thanks,
Chenyu


  reply	other threads:[~2023-08-30 19:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-29  6:50 Shrikanth Hegde
2023-08-30 13:16 ` Chen Yu [this message]
2023-08-30 16:02   ` Shrikanth Hegde

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=ZO9BSaGpF5lIAjzy@chenyu5-mobl2 \
    --to=yu.c.chen@intel.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=ionela.voinescu@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@techsingularity.net \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=quentin.perret@arm.com \
    --cc=srikar@linux.vnet.ibm.com \
    --cc=sshegde@linux.vnet.ibm.com \
    --cc=vincent.guittot@linaro.org \
    --cc=vschneid@redhat.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®