mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] thermal: intel: powerclamp: Do not log an error on unsupported CPUs
@ 2026-11-10 15:26 Breno Leitao
  0 siblings, 0 replies; only message in thread
From: Breno Leitao @ 2026-11-10 15:26 UTC (permalink / raw)
  To: Rafael J. Wysocki, Daniel Lezcano, Zhang Rui, Lukasz Luba, Jacob Pan
  Cc: linux-pm, linux-kernel, kernel-team, Breno Leitao

powerclamp_probe() returns -ENODEV unless x86_match_cpu() finds an
Intel CPU with MWAIT, and logs "CPU does not support MWAIT" at KERN_ERR
when it does not.

As a result, a kernel with CONFIG_INTEL_POWERCLAMP=y logs this error on
every boot on a non-Intel CPU.

  # grep -m1 vendor_id /proc/cpuinfo
  vendor_id	: AuthenticAMD
  # grep -m1 -o -w monitor /proc/cpuinfo
  monitor
  # dmesg -l err | grep intel_powerclamp:
  [    0.485728] intel_powerclamp: CPU does not support MWAIT

At KERN_ERR the line also gets past "quiet" and lands on the console,
and on kernel metrics.

Reduce it to debug, and also name both conditions in the message.

Signed-off-by: Breno Leitao <leitao@debian.org>
---
 drivers/thermal/intel/intel_powerclamp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/thermal/intel/intel_powerclamp.c b/drivers/thermal/intel/intel_powerclamp.c
index 1ffcb0a699e57d..82587dc8b0156f 100644
--- a/drivers/thermal/intel/intel_powerclamp.c
+++ b/drivers/thermal/intel/intel_powerclamp.c
@@ -695,7 +695,7 @@ static int __init powerclamp_probe(void)
 {
 
 	if (!x86_match_cpu(intel_powerclamp_ids)) {
-		pr_err("CPU does not support MWAIT\n");
+		pr_debug("CPU is not Intel or does not support MWAIT\n");
 		return -ENODEV;
 	}
 

---
base-commit: 630059a5a632377b9b7b487baccde92b7ae1dd47
base-tree: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
change-id: 20261110-powerclamp_mwait_msg-93bac0782c79

Best regards,
--  
Breno Leitao <leitao@debian.org>


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-11-10 15:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-10 15:26 [PATCH] thermal: intel: powerclamp: Do not log an error on unsupported CPUs Breno Leitao

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®