netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@vyatta.com>
To: David Miller <davem@davemloft.net>, Robert Olsson <robert@herjulf.net>
Cc: netdev@vger.kernel.org
Subject: [PATCH 2/2] pktgen: nmi watchdog keep alive
Date: Sat, 19 Sep 2009 22:21:03 -0700	[thread overview]
Message-ID: <20090919222103.017b5d5f@nehalam> (raw)

If pktgen gets really busy it takes up all the CPU,
and can starve the NMI thread and cause system reset.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>

--- a/net/core/pktgen.c	2009-09-19 11:28:53.762463050 -0700
+++ b/net/core/pktgen.c	2009-09-19 11:30:36.534459968 -0700
@@ -136,6 +136,7 @@
 #include <linux/delay.h>
 #include <linux/timer.h>
 #include <linux/list.h>
+#include <linux/nmi.h>
 #include <linux/init.h>
 #include <linux/skbuff.h>
 #include <linux/netdevice.h>
@@ -3369,6 +3370,7 @@ static void idle(struct pktgen_dev *pkt_
 {
 	ktime_t idle_start = ktime_now();
 
+	touch_nmi_watchdog();
 	if (need_resched())
 		schedule();
 	else

                 reply	other threads:[~2009-09-20  5:21 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20090919222103.017b5d5f@nehalam \
    --to=shemminger@vyatta.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=robert@herjulf.net \
    /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).