From: Thomas Graf <tgraf@suug.ch>
To: davem@davemloft.net
Cc: netdev@vger.kernel.org
Subject: [NET]: Don't do netpoll on per cpu backlog napi struct
Date: Wed, 22 Aug 2007 01:08:51 +0200 [thread overview]
Message-ID: <20070821230851.GP32236@postel.suug.ch> (raw)
The per cpu backlog napi struct can't do netpoll and has the
dev member set to NULL. Fixes an oops on boot when netpoll is
enabled.
Signed-off-by: Thomas Graf <tgraf@suug.ch>
Index: net-2.6.24/include/linux/netpoll.h
===================================================================
--- net-2.6.24.orig/include/linux/netpoll.h 2007-08-22 01:02:14.000000000 +0200
+++ net-2.6.24/include/linux/netpoll.h 2007-08-22 01:02:30.000000000 +0200
@@ -75,7 +75,7 @@ static inline void *netpoll_poll_lock(st
struct net_device *dev = napi->dev;
rcu_read_lock(); /* deal with race on ->npinfo */
- if (dev->npinfo) {
+ if (dev && dev->npinfo) {
spin_lock(&napi->poll_lock);
napi->poll_owner = smp_processor_id();
return napi;
next reply other threads:[~2007-08-21 23:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-21 23:08 Thomas Graf [this message]
2007-08-21 23:19 ` [NET]: Don't do netpoll on per cpu backlog napi struct David Miller
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=20070821230851.GP32236@postel.suug.ch \
--to=tgraf@suug.ch \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.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).