Return-Path: Message-Id: <20120321211448.777109178@linuxfoundation.org> Date: Wed, 21 Mar 2012 14:14:54 -0700 From: Greg KH To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, "RongQing.Li" , Eric Dumazet , "David S. Miller" Subject: [ 6/8] ipv6: Dont dev_hold(dev) in ip6_mc_find_dev_rcu. In-Reply-To: <20120321211522.GA28233@kroah.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: 3.0-stable review patch. If anyone has any objections, please let me know. ------------------ From: RongQing.Li [ Upstream commit c577923756b7fe9071f28a76b66b83b306d1d001 ] 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 in 96b52e61be1 (ipv6: mcast: RCU conversions) ] Signed-off-by: RongQing.Li Acked-by: Eric Dumazet Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- net/ipv6/mcast.c | 1 - 1 file changed, 1 deletion(-) --- a/net/ipv6/mcast.c +++ b/net/ipv6/mcast.c @@ -257,7 +257,6 @@ static struct inet6_dev *ip6_mc_find_dev if (rt) { dev = rt->rt6i_dev; - dev_hold(dev); dst_release(&rt->dst); } } else