* + nmi-watchdog-quiet-down-the-boot-messages.patch added to -mm tree
@ 2012-06-08 21:37 akpm
2012-06-11 8:47 ` Ingo Molnar
0 siblings, 1 reply; 3+ messages in thread
From: akpm @ 2012-06-08 21:37 UTC (permalink / raw)
To: mm-commits; +Cc: dzickus, joe, mingo, nzimmer
The patch titled
Subject: nmi watchdog: quiet down the boot messages
has been added to the -mm tree. Its filename is
nmi-watchdog-quiet-down-the-boot-messages.patch
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a
reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/SubmitChecklist when testing your code ***
The -mm tree is included into linux-next and is updated
there every 3-4 working days
------------------------------------------------------
From: Don Zickus <dzickus@redhat.com>
Subject: nmi watchdog: quiet down the boot messages
A bunch of bugzillas have complained how noisy the nmi_watchdog is during
boot-up especially with its expected failure cases (like virt and bios
resource contention).
This is my attempt to quiet them down and keep it less confusing for the
end user. What I did is print the message for cpu0 and save it for future
comparisons. If future cpus have an identical message as cpu0, then don't
print the redundant info. However, if a future cpu has a different
message, happily print that loudly.
Before the change, you would see something like:
..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
CPU0: Intel(R) Core(TM)2 Quad CPU Q9550 @ 2.83GHz stepping 0a
Performance Events: PEBS fmt0+, Core2 events, Intel PMU driver.
... version: 2
... bit width: 40
... generic registers: 2
... value mask: 000000ffffffffff
... max period: 000000007fffffff
... fixed-purpose events: 3
... event mask: 0000000700000003
NMI watchdog enabled, takes one hw-pmu counter.
Booting Node 0, Processors #1
NMI watchdog enabled, takes one hw-pmu counter.
#2
NMI watchdog enabled, takes one hw-pmu counter.
#3 Ok.
NMI watchdog enabled, takes one hw-pmu counter.
Brought up 4 CPUs
Total of 4 processors activated (22607.24 BogoMIPS).
After the change, it is simplified to:
..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
CPU0: Intel(R) Core(TM)2 Quad CPU Q9550 @ 2.83GHz stepping 0a
Performance Events: PEBS fmt0+, Core2 events, Intel PMU driver.
... version: 2
... bit width: 40
... generic registers: 2
... value mask: 000000ffffffffff
... max period: 000000007fffffff
... fixed-purpose events: 3
... event mask: 0000000700000003
NMI watchdog enabled, takes one hw-pmu counter.
Booting Node 0, Processors #1 #2 #3 Ok.
Brought up 4 CPUs
Signed-off-by: Don Zickus <dzickus@redhat.com>
Reported-by: Nathan Zimmer <nzimmer@sgi.com>
Tested-by: Nathan Zimmer <nzimmer@sgi.com>
Cc: Joe Perches <joe@perches.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
kernel/watchdog.c | 19 ++++++++++++++++++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff -puN kernel/watchdog.c~nmi-watchdog-quiet-down-the-boot-messages kernel/watchdog.c
--- a/kernel/watchdog.c~nmi-watchdog-quiet-down-the-boot-messages
+++ a/kernel/watchdog.c
@@ -377,6 +377,13 @@ static int watchdog_nmi_enable(int cpu)
struct perf_event_attr *wd_attr;
struct perf_event *event = per_cpu(watchdog_ev, cpu);
+ /*
+ * People like the simple clean cpu node info on boot.
+ * Reduce the watchdog noise by only printing messages
+ * that are different from what cpu0 displayed.
+ */
+ static unsigned long cpu0_err;
+
/* is it already setup and enabled? */
if (event && event->state > PERF_EVENT_STATE_OFF)
goto out;
@@ -390,11 +397,21 @@ static int watchdog_nmi_enable(int cpu)
/* Try to register using hardware perf events */
event = perf_event_create_kernel_counter(wd_attr, cpu, NULL, watchdog_overflow_callback, NULL);
+
+ /* save cpu0 error for future comparision */
+ if (cpu == 0 && IS_ERR(event))
+ cpu0_err = PTR_ERR(event);
+
if (!IS_ERR(event)) {
- pr_info("enabled, takes one hw-pmu counter.\n");
+ /* only print for cpu0 or different than cpu0 */
+ if (cpu ==0 || cpu0_err)
+ pr_info("enabled, takes one hw-pmu counter.\n");
goto out_save;
}
+ /* skip displaying the same error again */
+ if (cpu > 0 && (PTR_ERR(event) == cpu0_err))
+ return PTR_ERR(event);
/* vary the KERN level based on the returned errno */
if (PTR_ERR(event) == -EOPNOTSUPP)
_
Subject: Subject: nmi watchdog: quiet down the boot messages
Patches currently in -mm which might be from dzickus@redhat.com are
origin.patch
linux-next.patch
nmi-watchdog-quiet-down-the-boot-messages.patch
nmi-watchdog-fix-for-lockup-detector-breakage-on-resume.patch
nmi-watchdog-fix-for-lockup-detector-breakage-on-resume-fix.patch
nmi-watchdog-fix-for-lockup-detector-breakage-on-resume-fix-fix-fix.patch
nmi-watchdog-fix-for-lockup-detector-breakage-on-resume-fix-fix.patch
nmi-watchdog-fix-for-lockup-detector-breakage-on-resume-v2.patch
nmi-watchdog-fix-for-lockup-detector-breakage-on-resume-v2-fix.patch
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: + nmi-watchdog-quiet-down-the-boot-messages.patch added to -mm tree
2012-06-08 21:37 + nmi-watchdog-quiet-down-the-boot-messages.patch added to -mm tree akpm
@ 2012-06-11 8:47 ` Ingo Molnar
2012-06-11 13:18 ` Don Zickus
0 siblings, 1 reply; 3+ messages in thread
From: Ingo Molnar @ 2012-06-11 8:47 UTC (permalink / raw)
To: akpm, dzickus
Cc: mm-commits, dzickus, joe, mingo, nzimmer, linux-kernel,
Peter Zijlstra
* akpm@linux-foundation.org <akpm@linux-foundation.org> wrote:
> From: Don Zickus <dzickus@redhat.com>
> Subject: nmi watchdog: quiet down the boot messages
>
> A bunch of bugzillas have complained how noisy the nmi_watchdog is during
> boot-up especially with its expected failure cases (like virt and bios
> resource contention).
>
> This is my attempt to quiet them down and keep it less confusing for the
> end user. What I did is print the message for cpu0 and save it for future
> comparisons. If future cpus have an identical message as cpu0, then don't
> print the redundant info. However, if a future cpu has a different
> message, happily print that loudly.
>
> Before the change, you would see something like:
>
> ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
> CPU0: Intel(R) Core(TM)2 Quad CPU Q9550 @ 2.83GHz stepping 0a
> Performance Events: PEBS fmt0+, Core2 events, Intel PMU driver.
> ... version: 2
> ... bit width: 40
> ... generic registers: 2
> ... value mask: 000000ffffffffff
> ... max period: 000000007fffffff
> ... fixed-purpose events: 3
> ... event mask: 0000000700000003
> NMI watchdog enabled, takes one hw-pmu counter.
> Booting Node 0, Processors #1
> NMI watchdog enabled, takes one hw-pmu counter.
> #2
> NMI watchdog enabled, takes one hw-pmu counter.
> #3 Ok.
> NMI watchdog enabled, takes one hw-pmu counter.
> Brought up 4 CPUs
> Total of 4 processors activated (22607.24 BogoMIPS).
the problem really was that it didn't print which CPU it
referred to - it just repeated the same message over and over
again.
If it said:
NMI watchdog enabled on CPU#0, takes one hw-pmu counter.
it would be far less confusing.
This:
> After the change, it is simplified to:
>
> ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
> CPU0: Intel(R) Core(TM)2 Quad CPU Q9550 @ 2.83GHz stepping 0a
> Performance Events: PEBS fmt0+, Core2 events, Intel PMU driver.
> ... version: 2
> ... bit width: 40
> ... generic registers: 2
> ... value mask: 000000ffffffffff
> ... max period: 000000007fffffff
> ... fixed-purpose events: 3
> ... event mask: 0000000700000003
> NMI watchdog enabled, takes one hw-pmu counter.
> Booting Node 0, Processors #1 #2 #3 Ok.
> Brought up 4 CPUs
Is fine too but should be clarified to something like:
NMI watchdog enabled on all CPUs, permanently consumes one hw-PMU counter
(Please note the capitalization of 'PMU' as well.)
Thanks,
Ingo
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: + nmi-watchdog-quiet-down-the-boot-messages.patch added to -mm tree
2012-06-11 8:47 ` Ingo Molnar
@ 2012-06-11 13:18 ` Don Zickus
0 siblings, 0 replies; 3+ messages in thread
From: Don Zickus @ 2012-06-11 13:18 UTC (permalink / raw)
To: Ingo Molnar
Cc: akpm, mm-commits, joe, mingo, nzimmer, linux-kernel,
Peter Zijlstra
On Mon, Jun 11, 2012 at 10:47:44AM +0200, Ingo Molnar wrote:
> > NMI watchdog enabled, takes one hw-pmu counter.
> > Booting Node 0, Processors #1
> > NMI watchdog enabled, takes one hw-pmu counter.
> > #2
> > NMI watchdog enabled, takes one hw-pmu counter.
> > #3 Ok.
> > NMI watchdog enabled, takes one hw-pmu counter.
> > Brought up 4 CPUs
> > Total of 4 processors activated (22607.24 BogoMIPS).
>
> the problem really was that it didn't print which CPU it
> referred to - it just repeated the same message over and over
> again.
>
> If it said:
>
> NMI watchdog enabled on CPU#0, takes one hw-pmu counter.
>
> it would be far less confusing.
Sure. The problem SGI has with 4096 cpus is the volume. Specifying which
cpu the message belongs to, I do not think helps with this problem.
>
> This:
>
> > After the change, it is simplified to:
> >
> > ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
> > CPU0: Intel(R) Core(TM)2 Quad CPU Q9550 @ 2.83GHz stepping 0a
> > Performance Events: PEBS fmt0+, Core2 events, Intel PMU driver.
> > ... version: 2
> > ... bit width: 40
> > ... generic registers: 2
> > ... value mask: 000000ffffffffff
> > ... max period: 000000007fffffff
> > ... fixed-purpose events: 3
> > ... event mask: 0000000700000003
> > NMI watchdog enabled, takes one hw-pmu counter.
> > Booting Node 0, Processors #1 #2 #3 Ok.
> > Brought up 4 CPUs
>
> Is fine too but should be clarified to something like:
>
> NMI watchdog enabled on all CPUs, permanently consumes one hw-PMU counter
>
> (Please note the capitalization of 'PMU' as well.)
Ok. I can modify that.
Cheers,
Don
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-06-11 13:18 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-08 21:37 + nmi-watchdog-quiet-down-the-boot-messages.patch added to -mm tree akpm
2012-06-11 8:47 ` Ingo Molnar
2012-06-11 13:18 ` Don Zickus
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.