mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hugh Dickins <hugh.dickins@tiscali.co.uk>
To: Dmitry Torokhov <dtor@mail.ru>
Cc: "H. Peter Anvin" <hpa@zytor.com>, Ingo Molnar <mingo@elte.hu>,
	Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>,
	Andi Kleen <andi@firstfloor.org>,
	linux-kernel@vger.kernel.org
Subject: [PATCH] x86, mce: therm_throt: don't log redundant normality
Date: Sun, 16 Aug 2009 15:54:37 +0100 (BST)	[thread overview]
Message-ID: <Pine.LNX.4.64.0908161544100.7929@sister.anvils> (raw)

Hi Dmitry,

I'm delighted to find your 0d01f31439c1e4d602bf9fdc924ab66f407f5e38
"x86, mce: therm_throt - change when we print messages" in rc6:
thank you.

I too had been annoyed by "critical" CPU1 Temperature/speed normal
messages, with no indication that anything had been abnormal: after
resume on a Fujitsu-Siemens Esprimo Mobile (whereas startup decided
the Duo's CPU0 Thermal monitoring would be handled by SMI not by MCE).

I hadn't reported it yet, because I couldn't quite work out what to do
about it: your patch looks good, so long as someone else doesn't have
a machine which jumps between throttled and unthrottled too quickly.

But could we add one more thing on top of your patch?  Though it no
longer keeps announcing "I am normal", can we please also get rid
of the accompanying "Machine check events logged" message too?
If the non-event isn't worth showing (I agree that it isn't),
then I think it's not worth logging either.

Hugh


[PATCH] x86, mce: therm_throt - don't log redundant normality

0d01f31439c1e4d602bf9fdc924ab66f407f5e38 "x86, mce: therm_throt -
change when we print messages" removed redundant announcements of
"Temperature/speed normal".  They're not worth logging either:
remove their accompanying "Machine check events logged" messages.

Signed-off-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
---

 arch/x86/kernel/cpu/mcheck/therm_throt.c |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

--- 2.6.31-rc6/arch/x86/kernel/cpu/mcheck/therm_throt.c	2009-08-14 09:34:06.000000000 +0100
+++ linux/arch/x86/kernel/cpu/mcheck/therm_throt.c	2009-08-14 13:22:07.000000000 +0100
@@ -116,11 +116,14 @@ static int therm_throt_process(int curr)
 		       cpu, __get_cpu_var(thermal_throttle_count));
 
 		add_taint(TAINT_MACHINE_CHECK);
-	} else if (was_throttled) {
+		return 1;
+	}
+	if (was_throttled) {
 		printk(KERN_INFO "CPU%d: Temperature/speed normal\n", cpu);
+		return 1;
 	}
 
-	return 1;
+	return 0;
 }
 
 #ifdef CONFIG_SYSFS

             reply	other threads:[~2009-08-16 14:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-16 14:54 Hugh Dickins [this message]
2009-08-16 15:26 ` Ingo Molnar
2009-08-16 15:27 ` [tip:x86/urgent] x86, mce: therm_throt: Don't " tip-bot for Hugh Dickins

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=Pine.LNX.4.64.0908161544100.7929@sister.anvils \
    --to=hugh.dickins@tiscali.co.uk \
    --cc=andi@firstfloor.org \
    --cc=dtor@mail.ru \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=seto.hidetoshi@jp.fujitsu.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®