From: David Vrabel <david.vrabel@citrix.com>
To: xen-devel@lists.xenproject.org
Cc: Keir Fraser <keir@xen.org>,
David Vrabel <david.vrabel@citrix.com>,
Jan Beulich <jbeulich@suse.com>
Subject: [PATCH 4/4] x86/nmi: be less verbose when testing the NMI watchdog
Date: Wed, 14 May 2014 13:58:19 +0100 [thread overview]
Message-ID: <1400072299-2285-5-git-send-email-david.vrabel@citrix.com> (raw)
In-Reply-To: <1400072299-2285-1-git-send-email-david.vrabel@citrix.com>
There's no need to print all the CPUs that are ok, only the ones that
got stuck.
The resulting output is either:
Testing NMI watchdog on all CPUs: 1 4 6 stuck
or
Testing NMI watchdog on all CPUs: ok
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
---
xen/arch/x86/nmi.c | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/xen/arch/x86/nmi.c b/xen/arch/x86/nmi.c
index 4f330d8..84c1a5e 100644
--- a/xen/arch/x86/nmi.c
+++ b/xen/arch/x86/nmi.c
@@ -125,11 +125,12 @@ int __init check_nmi_watchdog (void)
{
static unsigned int __initdata prev_nmi_count[NR_CPUS];
int cpu;
-
+ bool_t ok = 1;
+
if ( !nmi_watchdog )
return 0;
- printk("Testing NMI watchdog --- ");
+ printk("Testing NMI watchdog on all CPUs:");
for_each_online_cpu ( cpu )
prev_nmi_count[cpu] = nmi_count(cpu);
@@ -141,12 +142,13 @@ int __init check_nmi_watchdog (void)
for_each_online_cpu ( cpu )
{
if ( nmi_count(cpu) - prev_nmi_count[cpu] <= 5 )
- printk("CPU#%d stuck. ", cpu);
- else
- printk("CPU#%d okay. ", cpu);
+ {
+ printk(" %d", cpu);
+ ok = 0;
+ }
}
- printk("\n");
+ printk(" %s\n", ok ? "ok" : "stuck");
/*
* Now that we know it works we can reduce NMI frequency to
--
1.7.10.4
next prev parent reply other threads:[~2014-05-14 12:58 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-14 12:58 [PATCH 0/4] x86/nmi: improve NMI watchdog test David Vrabel
2014-05-14 12:58 ` [PATCH 1/4] x86/nmi: remove spurious local_irq_enable from check_nmi_watchdog() David Vrabel
2014-05-14 13:25 ` Jan Beulich
2014-05-14 13:31 ` David Vrabel
2014-05-14 13:53 ` Jan Beulich
2014-05-15 11:40 ` Tim Deegan
2014-05-14 12:58 ` [PATCH 2/4] x86/nmi: enable local irqs in wait_for_nmis() David Vrabel
2014-05-14 13:57 ` Jan Beulich
2014-05-14 14:38 ` David Vrabel
2014-05-14 14:45 ` Jan Beulich
2014-05-15 11:55 ` Tim Deegan
2014-05-14 12:58 ` [PATCH 3/4] x86/nmi: wait for all CPUs in check_nmi_watchdog() David Vrabel
2014-05-14 13:59 ` Jan Beulich
2014-05-14 14:09 ` David Vrabel
2014-05-14 14:33 ` Jan Beulich
2014-05-14 14:09 ` Andrew Cooper
2014-05-15 11:47 ` Tim Deegan
2014-05-14 12:58 ` David Vrabel [this message]
2014-05-15 11:48 ` [PATCH 4/4] x86/nmi: be less verbose when testing the NMI watchdog Tim Deegan
2014-05-14 13:03 ` [PATCH 0/4] x86/nmi: improve NMI watchdog test Andrew Cooper
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=1400072299-2285-5-git-send-email-david.vrabel@citrix.com \
--to=david.vrabel@citrix.com \
--cc=jbeulich@suse.com \
--cc=keir@xen.org \
--cc=xen-devel@lists.xenproject.org \
/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;
as well as URLs for NNTP newsgroup(s).