Thread (11 messages) 11 messages, 3 authors, 2017-12-03

Re: [Patch net-next] act_mirred: get rid of mirred_list_lock spinlock

From: Cong Wang <hidden>
Date: 2017-12-01 01:02:59

On Thu, Nov 30, 2017 at 3:12 PM, Eric Dumazet [off-list ref] wrote:
On Thu, 2017-11-30 at 14:53 -0800, Cong Wang wrote:
quoted
@@ -55,13 +54,10 @@ static void tcf_mirred_release(struct tc_action
*a, int bind)
      struct tcf_mirred *m = to_mirred(a);
      struct net_device *dev;

-     /* We could be called either in a RCU callback or with RTNL
lock held. */
-     spin_lock_bh(&mirred_list_lock);
      list_del(&m->tcfm_list);
      dev = rcu_dereference_protected(m->tcfm_dev, 1);
If RTNL is held at this point, I suggest to use
rtnl_dereference() instead of rcu_dereference_protected() to get proper
lockdep coverage.
Ah, sure, I missed it. Will send v2 later.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help