Commit 0a24c43f authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller

ip6mr: do not get a device reference in pim6_rcv()

pim6_rcv() is called under rcu_read_lock(), there is
no need to use dev_hold()/dev_put() pair.

IPv4 side was handled in commit 55747a0a
("ipmr: __pim_rcv() is called under rcu_read_lock")
Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 7fcb820c
......@@ -554,7 +554,6 @@ static int pim6_rcv(struct sk_buff *skb)
read_lock(&mrt_lock);
if (reg_vif_num >= 0)
reg_dev = mrt->vif_table[reg_vif_num].dev;
dev_hold(reg_dev);
read_unlock(&mrt_lock);
if (!reg_dev)
......@@ -570,7 +569,6 @@ static int pim6_rcv(struct sk_buff *skb)
netif_rx(skb);
dev_put(reg_dev);
return 0;
drop:
kfree_skb(skb);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment