mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Christian Loehle <christian.loehle@arm.com>
To: Sumit Gupta <sumitg@nvidia.com>,
	rafael@kernel.org, viresh.kumar@linaro.org,
	pierre.gondois@arm.com, ionela.voinescu@arm.com,
	zhenglifeng1@huawei.com, zhanjie9@hisilicon.com, lenb@kernel.org,
	mario.limonciello@amd.com, maciej.wieczor-retman@intel.com,
	pawel.chmielewski@intel.com, linux-pm@vger.kernel.org,
	linux-acpi@vger.kernel.org, acpica-devel@lists.linux.dev,
	linux-kernel@vger.kernel.org
Cc: linux-tegra@vger.kernel.org, treding@nvidia.com,
	jonathanh@nvidia.com, vsethi@nvidia.com, ksitaraman@nvidia.com,
	sanjayc@nvidia.com, mochs@nvidia.com, bbasu@nvidia.com
Subject: Re: [PATCH v8 3/3] cpufreq: CPPC: Reflect the OSPM nominal in boost and limits
Date: Wed, 4 Nov 2026 15:16:02 +0000	[thread overview]
Message-ID: <79700c48-e031-422a-a6b6-8c4118131e98@arm.com> (raw)
In-Reply-To: <4d9aa879-316c-4188-bc5a-71e3b65e8a3b@nvidia.com>

On 11/4/26 15:08, Sumit Gupta wrote:
> Hi Christian,
> 
> 
> On 03/11/26 22:42, Christian Loehle wrote:
>> External email: Use caution opening links or attachments
>>
>>
>> On 10/30/26 17:27, Sumit Gupta wrote:
>>> Boost is the performance range above nominal, so lowering the OSPM
>>> Nominal Performance enlarges the boost range and drops the non-boost
>>> ceiling. Keep the policy limits consistent with the register.
>>>
>>> Add cppc_cpufreq_effective_nominal(), which returns the OSPM Nominal
>>> Performance when set and the platform nominal otherwise. Use it for the
>>> non-boost ceiling in set_boost(), and to update the policy limits when
>>> ospm_nominal_freq is written.
>>>
>>> The cpufreq core caps scaling_max_freq with a per-policy QoS request,
>>> boost_freq_req, that it sets to cpuinfo.max_freq and refreshes only when
>>> boost is toggled. A write to ospm_nominal_freq changes cpuinfo.max_freq
>>> without toggling boost, so cppc_cpufreq_update_nominal_limits() updates
>>> the request itself, rather than leaving scaling_max_freq at the old
>>> nominal.
>>>
>>> When boost is enabled the ceiling is highest_perf, not the nominal, so
>>> the update is skipped. set_boost() applies the new nominal when boost is
>>> turned off.
>>>
>>> A platform with highest_perf == nominal_perf has no boost range at boot.
>>> Lowering the OSPM nominal from sysfs can create one. The core, however,
>>> adds its boost FREQ_QOS_MAX request only at policy setup, and only if
>>> boost_supported is already set. Set boost_supported in init() when the
>>> OSPM register is supported and highest_perf > lowest_perf. Boost can
>>> then be enabled after the nominal is lowered.
>>>
>>> Suggested-by: Pierre Gondois <pierre.gondois@arm.com>
>>> Signed-off-by: Sumit Gupta <sumitg@nvidia.com>
>>
>> Thinking out loud here:
>> I'm curious if there's actually a use-case for this, presumably once we
>> let userspace effectively dictate boost allocation, we practically expect
>> userspace to sort out scheduling, too (e.g. by pinning?) and therefore this
>> becomes largely irrelevant?
>>
> 
> I think it is still needed. Lowering the OSPM nominal puts the levels
> between it and the platform nominal into the boost range.
> Without this patch, boost=0 still allows those levels. Userspace would
> then need an extra frequency cap to stay out of boost. This patch makes
> boost=0 cap the policy at the OSPM nominal.

Duh of course, I was somehow too focused on the cpufreq capacity pressure
to not see the obvious one, nevermind and sorry for the noise.

Reviewed-by: Christian Loehle <christian.loehle@arm.com>


      reply	other threads:[~2026-11-04 15:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-30 17:27 [PATCH v8 0/3] ACPI / cpufreq: CPPC: Add ospm_nominal_perf support Sumit Gupta
2026-10-30 17:27 ` [PATCH v8 1/3] ACPI: " Sumit Gupta
2026-11-04 17:39   ` Christian Loehle
2026-10-30 17:27 ` [PATCH v8 2/3] cpufreq: CPPC: Add ospm_nominal_freq attribute Sumit Gupta
2026-11-04 17:39   ` Christian Loehle
2026-10-30 17:27 ` [PATCH v8 3/3] cpufreq: CPPC: Reflect the OSPM nominal in boost and limits Sumit Gupta
2026-11-03 17:12   ` Christian Loehle
2026-11-04 15:08     ` Sumit Gupta
2026-11-04 15:16       ` Christian Loehle [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=79700c48-e031-422a-a6b6-8c4118131e98@arm.com \
    --to=christian.loehle@arm.com \
    --cc=acpica-devel@lists.linux.dev \
    --cc=bbasu@nvidia.com \
    --cc=ionela.voinescu@arm.com \
    --cc=jonathanh@nvidia.com \
    --cc=ksitaraman@nvidia.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=maciej.wieczor-retman@intel.com \
    --cc=mario.limonciello@amd.com \
    --cc=mochs@nvidia.com \
    --cc=pawel.chmielewski@intel.com \
    --cc=pierre.gondois@arm.com \
    --cc=rafael@kernel.org \
    --cc=sanjayc@nvidia.com \
    --cc=sumitg@nvidia.com \
    --cc=treding@nvidia.com \
    --cc=viresh.kumar@linaro.org \
    --cc=vsethi@nvidia.com \
    --cc=zhanjie9@hisilicon.com \
    --cc=zhenglifeng1@huawei.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®