mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-03 01:36:52 +09:00
ipv6: Don't dev_hold(dev) in ip6_mc_find_dev_rcu.
[ Upstream commitc577923756] ip6_mc_find_dev_rcu() is called with rcu_read_lock(), so don't need to dev_hold(). With dev_hold(), not corresponding dev_put(), will lead to leak. [ bug introduced in96b52e61be(ipv6: mcast: RCU conversions) ] Signed-off-by: RongQing.Li <roy.qing.li@gmail.com> Acked-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
137a954db9
commit
97490c46fe
@@ -257,7 +257,6 @@ static struct inet6_dev *ip6_mc_find_dev_rcu(struct net *net,
|
||||
|
||||
if (rt) {
|
||||
dev = rt->rt6i_dev;
|
||||
dev_hold(dev);
|
||||
dst_release(&rt->dst);
|
||||
}
|
||||
} else
|
||||
|
||||
Reference in New Issue
Block a user