mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sumit Gupta <sumitg@nvidia.com>
To: "Rafael J. Wysocki (Intel)" <rafael@kernel.org>
Cc: viresh.kumar@linaro.org, pierre.gondois@arm.com,
	christian.loehle@arm.com, ionela.voinescu@arm.com,
	zhenglifeng1@huawei.com, zhanjie9@hisilicon.com,
	ray.huang@amd.com, mario.limonciello@amd.com, perry.yuan@amd.com,
	kprateek.nayak@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, 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 v9 6/8] ACPI: CPPC: Add ospm_nominal_perf support
Date: Tue, 10 Nov 2026 01:38:53 +0530	[thread overview]
Message-ID: <00951541-0684-41d7-a367-d63126bfa453@nvidia.com> (raw)
In-Reply-To: <CAJZ5v0gYO4cw8CFbeRJAv1_cQ1WxrsTBC9yJ15NsrBX4rDM6LQ@mail.gmail.com>



On 09/11/26 22:34, Rafael J. Wysocki (Intel) wrote:
> External email: Use caution opening links or attachments
> 
> 
> On Mon, Nov 9, 2026 at 6:01 PM Rafael J. Wysocki (Intel)
> <rafael@kernel.org> wrote:
>>
>> On Fri, Nov 6, 2026 at 8:35 PM Sumit Gupta <sumitg@nvidia.com> wrote:
>>>
>>> Expose the OSPM Nominal Performance register (ACPI 6.6, Section
>>> 8.4.6.1.2.6), which conveys the nominal performance level at which the
>>> platform may run. Unlike the read-only Nominal Performance register, it
>>> is writable, so OSPM can ask for a nominal level below the
>>> platform-reported one, which then becomes the boundary between boosted
>>> and throttled operation.
>>>
>>> Add cppc_set_ospm_nominal_perf() to write the register. Per the spec,
>>> the value must lie in [Lowest Performance, Nominal Performance], which
>>> the caller is responsible for validating.
>>>
>>> Add cppc_ospm_nominal_perf_supported() to report whether the platform
>>> implements the register as writable, since a write-only register cannot
>>> be probed by reading it. It uses the same cpc_is_writable() test as the
>>> setter, so support is never reported for a register that a write would
>>> reject, and takes cpc_desc_lock while looking the descriptor up.
>>>
>>> The register also joins the writable set that the SystemMemory overlap
>>> validation uses, as the driver now writes it and can compete with
>>> another control sharing an access unit.
>>>
>>> Reviewed-by: Christian Loehle <christian.loehle@arm.com>
>>> Signed-off-by: Sumit Gupta <sumitg@nvidia.com>
>>> ---
>>>   drivers/acpi/cppc_acpi.c | 44 ++++++++++++++++++++++++++++++++++++++++
>>>   include/acpi/cppc_acpi.h | 10 +++++++++
>>>   2 files changed, 54 insertions(+)
>>>
>>> diff --git a/drivers/acpi/cppc_acpi.c b/drivers/acpi/cppc_acpi.c
>>> index 5a1f84fddb7f..3a0ecdd1ab11 100644
>>> --- a/drivers/acpi/cppc_acpi.c
>>> +++ b/drivers/acpi/cppc_acpi.c
>>> @@ -463,6 +463,7 @@ static bool cpc_reg_is_writable(unsigned int reg_idx)
>>>          case AUTO_SEL_ENABLE:
>>>          case AUTO_ACT_WINDOW:
>>>          case ENERGY_PERF:
>>> +       case OSPM_NOMINAL_PERF:
>>
>> Sashiko is unhappy about this change:
>>
>> https://sashiko.dev/#/patchset/20261106193304.3347374-1-sumitg%40nvidia.com
> 
> So I've queued up patches [1-5/8] for 7.5 and I'll wait for a
> clarification here.

Hi Rafael,

Thanks for queuing 1-5.

Sorry, I missed this Sashiko error.

In v9, if OSPM_NOMINAL_PERF shares an access unit with Performance
Limited, its range is no longer checked for overlaps.
It is write-only, so another field's read-modify-write over it would
write undefined bits into it.
v10 keeps its range reserved, so such a layout is still rejected.

Sent v10 of patches 6-8 on top of the queued 1-5 [1].

[1] https://lore.kernel.org/lkml/20261109195400.3600561-1-sumitg@nvidia.com/

Thanks,
Sumit


  reply	other threads:[~2026-11-09 20:09 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-06 19:32 [PATCH v9 0/8] ACPI / cpufreq: CPPC: Preserve OSPM-set registers and add ospm_nominal_perf Sumit Gupta
2026-11-06 19:32 ` [PATCH v9 1/8] ACPI: CPPC: Order performance-control updates Sumit Gupta
2026-11-06 21:38   ` Sumit Gupta
2026-11-09 16:57     ` Rafael J. Wysocki (Intel)
2026-11-06 19:32 ` [PATCH v9 2/8] cpufreq: CPPC: Keep the policy across CPU hotplug Sumit Gupta
2026-11-06 19:32 ` [PATCH v9 3/8] ACPI: CPPC: Make autonomous selection helpers take a u64 Sumit Gupta
2026-11-06 19:33 ` [PATCH v9 4/8] cpufreq: CPPC: Preserve OSPM-set registers across hotplug and unload Sumit Gupta
2026-11-06 19:33 ` [PATCH v9 5/8] cpufreq: CPPC: Preserve OSPM-set registers across suspend/resume Sumit Gupta
2026-11-06 19:33 ` [PATCH v9 6/8] ACPI: CPPC: Add ospm_nominal_perf support Sumit Gupta
2026-11-09 17:01   ` Rafael J. Wysocki (Intel)
2026-11-09 17:04     ` Rafael J. Wysocki (Intel)
2026-11-09 20:08       ` Sumit Gupta [this message]
2026-11-06 19:33 ` [PATCH v9 7/8] cpufreq: CPPC: Add ospm_nominal_freq attribute Sumit Gupta
2026-11-06 19:33 ` [PATCH v9 8/8] cpufreq: CPPC: Reflect the OSPM nominal in boost and limits Sumit Gupta

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=00951541-0684-41d7-a367-d63126bfa453@nvidia.com \
    --to=sumitg@nvidia.com \
    --cc=acpica-devel@lists.linux.dev \
    --cc=bbasu@nvidia.com \
    --cc=christian.loehle@arm.com \
    --cc=ionela.voinescu@arm.com \
    --cc=jonathanh@nvidia.com \
    --cc=kprateek.nayak@amd.com \
    --cc=ksitaraman@nvidia.com \
    --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=perry.yuan@amd.com \
    --cc=pierre.gondois@arm.com \
    --cc=rafael@kernel.org \
    --cc=ray.huang@amd.com \
    --cc=sanjayc@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®