* [PATCH] platform/x86/intel-uncore-freq: Continue restoring limits on resume
@ 2026-09-29 16:31 Guixiong Wei
2026-09-30 20:28 ` srinivas pandruvada
2026-10-12 15:55 ` Ilpo Järvinen
0 siblings, 2 replies; 3+ messages in thread
From: Guixiong Wei @ 2026-09-29 16:31 UTC (permalink / raw)
To: srinivas.pandruvada
Cc: hansg, ilpo.jarvinen, rafael.j.wysocki, platform-driver-x86,
linux-kernel, wangyijia.yeah, Guixiong Wei, stable
The PM notifier iterates over every uncore frequency instance to restore
user-configured MSR_UNCORE_RATIO_LIMIT values after resume. Entries that
have never been configured legitimately have stored_uncore_data set to
zero.
The refactoring that split common and enumeration code changed the
iteration from active control CPUs to all allocated instances. It also
changed the skip for an invalid or unconfigured entry from continue to
return, causing that entry to terminate the entire restore operation.
On a multi-package or multi-die system, configuring only a later instance
therefore leaves its limit unrestored after suspend, hibernation, or
restore if an earlier entry is invalid or unconfigured.
Use continue to skip only the current entry and restore all remaining
configured instances.
Fixes: dbce412a7733 ("platform/x86/intel-uncore-freq: Split common and enumeration part")
Cc: stable@vger.kernel.org
Tested-by: Yijia Wang <wangyijia.yeah@bytedance.com>
Signed-off-by: Guixiong Wei <weiguixiong@bytedance.com>
---
drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c b/drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c
index 667f2c8b9594a..c44e7e38cae25 100644
--- a/drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c
+++ b/drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c
@@ -211,7 +211,7 @@ static int uncore_pm_notify(struct notifier_block *nb, unsigned long mode,
struct uncore_data *data = &uncore_instances[i];
if (!data || !data->valid || !data->stored_uncore_data)
- return 0;
+ continue;
wrmsrq_on_cpu(data->control_cpu, MSR_UNCORE_RATIO_LIMIT,
data->stored_uncore_data);
--
2.50.1 (Apple Git-155)
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] platform/x86/intel-uncore-freq: Continue restoring limits on resume
2026-09-29 16:31 [PATCH] platform/x86/intel-uncore-freq: Continue restoring limits on resume Guixiong Wei
@ 2026-09-30 20:28 ` srinivas pandruvada
2026-10-12 15:55 ` Ilpo Järvinen
1 sibling, 0 replies; 3+ messages in thread
From: srinivas pandruvada @ 2026-09-30 20:28 UTC (permalink / raw)
To: Guixiong Wei
Cc: hansg, ilpo.jarvinen, rafael.j.wysocki, platform-driver-x86,
linux-kernel, wangyijia.yeah, stable
On Wed, 2026-09-30 at 00:31 +0800, Guixiong Wei wrote:
> The PM notifier iterates over every uncore frequency instance to
> restore
> user-configured MSR_UNCORE_RATIO_LIMIT values after resume. Entries
> that
> have never been configured legitimately have stored_uncore_data set
> to
> zero.
>
> The refactoring that split common and enumeration code changed the
> iteration from active control CPUs to all allocated instances. It
> also
> changed the skip for an invalid or unconfigured entry from continue
> to
> return, causing that entry to terminate the entire restore operation.
>
> On a multi-package or multi-die system, configuring only a later
> instance
> therefore leaves its limit unrestored after suspend, hibernation, or
> restore if an earlier entry is invalid or unconfigured.
>
> Use continue to skip only the current entry and restore all remaining
> configured instances.
>
> Fixes: dbce412a7733 ("platform/x86/intel-uncore-freq: Split common
> and enumeration part")
> Cc: stable@vger.kernel.org
> Tested-by: Yijia Wang <wangyijia.yeah@bytedance.com>
> Signed-off-by: Guixiong Wei <weiguixiong@bytedance.com>
Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> ---
> drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c | 2
> +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/platform/x86/intel/uncore-frequency/uncore-
> frequency.c b/drivers/platform/x86/intel/uncore-frequency/uncore-
> frequency.c
> index 667f2c8b9594a..c44e7e38cae25 100644
> --- a/drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c
> +++ b/drivers/platform/x86/intel/uncore-frequency/uncore-frequency.c
> @@ -211,7 +211,7 @@ static int uncore_pm_notify(struct notifier_block
> *nb, unsigned long mode,
> struct uncore_data *data =
> &uncore_instances[i];
>
> if (!data || !data->valid || !data-
> >stored_uncore_data)
> - return 0;
> + continue;
>
> wrmsrq_on_cpu(data->control_cpu,
> MSR_UNCORE_RATIO_LIMIT,
> data->stored_uncore_data);
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] platform/x86/intel-uncore-freq: Continue restoring limits on resume
2026-09-29 16:31 [PATCH] platform/x86/intel-uncore-freq: Continue restoring limits on resume Guixiong Wei
2026-09-30 20:28 ` srinivas pandruvada
@ 2026-10-12 15:55 ` Ilpo Järvinen
1 sibling, 0 replies; 3+ messages in thread
From: Ilpo Järvinen @ 2026-10-12 15:55 UTC (permalink / raw)
To: srinivas.pandruvada, Guixiong Wei
Cc: hansg, rafael.j.wysocki, platform-driver-x86, linux-kernel,
wangyijia.yeah, stable
On Wed, 30 Sep 2026 00:31:34 +0800, Guixiong Wei wrote:
> The PM notifier iterates over every uncore frequency instance to restore
> user-configured MSR_UNCORE_RATIO_LIMIT values after resume. Entries that
> have never been configured legitimately have stored_uncore_data set to
> zero.
>
> The refactoring that split common and enumeration code changed the
> iteration from active control CPUs to all allocated instances. It also
> changed the skip for an invalid or unconfigured entry from continue to
> return, causing that entry to terminate the entire restore operation.
>
> [...]
Thank you for your contribution, it has been applied to my local
review-ilpo-next branch. Note it will show up in the public
platform-drivers-x86/review-ilpo-next branch only once I've pushed my
local branch there, which might take a while.
FYI [if applicable to your patch], as per Linus' policy change, also
fixes are mostly routed through for-next unless the fix is for a
commit introduced in the most recent cycle or is clearly a regression
fix.
The list of commits applied:
[1/1] platform/x86/intel-uncore-freq: Continue restoring limits on resume
commit: 8c1d61297a88cc7f7b2daab7b86c3e85639b46df
--
i.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-10-12 15:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-29 16:31 [PATCH] platform/x86/intel-uncore-freq: Continue restoring limits on resume Guixiong Wei
2026-09-30 20:28 ` srinivas pandruvada
2026-10-12 15:55 ` Ilpo Järvinen
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.