From: Dave Jones Subject: Re: bond: take rcu lock in bond_poll_controller Date: Fri, 28 Sep 2018 15:49:24 -0400 Message-ID: <20180928194924.p4enqz3zzcdox7cf@codemonkey.org.uk> References: <20180924192317.wghbs34ld7klqpi6@codemonkey.org.uk> <20180926.201541.2129538853102457012.davem@davemloft.net> <20180928161631.3pab3m2k6zvoemnz@codemonkey.org.uk> <20180928182410.slizlkx6fiwkyb76@codemonkey.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Linux Kernel Network Developers To: Cong Wang Return-path: Received: from scorn.kernelslacker.org ([45.56.101.199]:46600 "EHLO scorn.kernelslacker.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726405AbeI2COm (ORCPT ); Fri, 28 Sep 2018 22:14:42 -0400 Content-Disposition: inline In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: On Fri, Sep 28, 2018 at 12:03:22PM -0700, Cong Wang wrote: > On Fri, Sep 28, 2018 at 12:02 PM Cong Wang wrote: > > > > On Fri, Sep 28, 2018 at 11:26 AM Dave Jones wrote: > > > diff --git a/net/core/netpoll.c b/net/core/netpoll.c > > > index 3219a2932463..4f9494381635 100644 > > > --- a/net/core/netpoll.c > > > +++ b/net/core/netpoll.c > > > @@ -330,6 +330,7 @@ void netpoll_send_skb_on_dev(struct netpoll *np, struct sk_buff *skb, > > > /* It is up to the caller to keep npinfo alive. */ > > > struct netpoll_info *npinfo; > > > > > > + rcu_read_lock(); > > > lockdep_assert_irqs_disabled(); > > > > > > npinfo = rcu_dereference_bh(np->dev->npinfo); > > > > I think you probably need rcu_read_lock_bh() to satisfy > > rcu_deference_bh()... > > But irq is disabled here, so not sure if rcu_read_lock_bh() > could cause trouble... Interesting... I was wondering for a moment why I never got a warning, then I remembered I disabled lockdep for that machine because nfs spews stuff. I'll doublecheck, and post v4. lol, this looked like a 2 minute fix at first. Dave