Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Dave Jones
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 > > > ---

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Cong Wang
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

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Cong Wang
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,

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Eric Dumazet
On 09/28/2018 11:24 AM, Dave Jones wrote: > Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, > otherwise a trace like below is shown > > WARNING: CPU: 2 PID: 179 at net/core/dev.c:6567 > netdev_lower_get_next_private_rcu+0x34/0x40 > CPU: 2 PID: 179 Comm: kworker/u16:15

bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Dave Jones
Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, otherwise a trace like below is shown WARNING: CPU: 2 PID: 179 at net/core/dev.c:6567 netdev_lower_get_next_private_rcu+0x34/0x40 CPU: 2 PID: 179 Comm: kworker/u16:15 Not tainted 4.19.0-rc5-backup+ #1 Workqueue: bond0

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Dave Jones
On Fri, Sep 28, 2018 at 10:31:39AM -0700, Cong Wang wrote: > On Fri, Sep 28, 2018 at 10:25 AM Dave Jones wrote: > > > > On Fri, Sep 28, 2018 at 09:55:52AM -0700, Cong Wang wrote: > > > On Fri, Sep 28, 2018 at 9:18 AM Dave Jones > > wrote: > > > > > > > > Callers of

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Cong Wang
On Fri, Sep 28, 2018 at 10:25 AM Dave Jones wrote: > > On Fri, Sep 28, 2018 at 09:55:52AM -0700, Cong Wang wrote: > > On Fri, Sep 28, 2018 at 9:18 AM Dave Jones wrote: > > > > > > Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, > > > otherwise a trace like below is

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Dave Jones
On Fri, Sep 28, 2018 at 09:55:52AM -0700, Cong Wang wrote: > On Fri, Sep 28, 2018 at 9:18 AM Dave Jones wrote: > > > > Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, > > otherwise a trace like below is shown > > So why not take rcu read lock in

Re: bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Cong Wang
On Fri, Sep 28, 2018 at 9:18 AM Dave Jones wrote: > > Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, > otherwise a trace like below is shown So why not take rcu read lock in netpoll_send_skb_on_dev() where RCU is also assumed? As I said, I can't explain why you didn't

bond: take rcu lock in bond_poll_controller

2018-09-28 Thread Dave Jones
Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, otherwise a trace like below is shown WARNING: CPU: 2 PID: 179 at net/core/dev.c:6567 netdev_lower_get_next_private_rcu+0x34/0x40 CPU: 2 PID: 179 Comm: kworker/u16:15 Not tainted 4.19.0-rc5-backup+ #1 Workqueue: bond0

Re: bond: take rcu lock in bond_poll_controller

2018-09-26 Thread David Miller
From: Dave Jones Date: Mon, 24 Sep 2018 15:23:17 -0400 > Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, > otherwise a trace like below is shown ... > Signed-off-by: Dave Jones Hey Dave, after some recent changes by Eric Dumazet this no longer applies. Please respin

Re: bond: take rcu lock in bond_poll_controller

2018-09-25 Thread Cong Wang
On Mon, Sep 24, 2018 at 1:08 PM Dave Jones wrote: > > Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, > otherwise a trace like below is shown Interesting, netpoll_send_skb_on_dev() already assumes RCU read lock when it calls rcu_dereference_bh()... I wonder how it can't

bond: take rcu lock in bond_poll_controller

2018-09-24 Thread Dave Jones
Callers of bond_for_each_slave_rcu are expected to hold the rcu lock, otherwise a trace like below is shown WARNING: CPU: 2 PID: 179 at net/core/dev.c:6567 netdev_lower_get_next_private_rcu+0x34/0x40 CPU: 2 PID: 179 Comm: kworker/u16:15 Not tainted 4.19.0-rc5-backup+ #1 Workqueue: bond0