From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH net] net/ipv6: fix metrics leak Date: Mon, 30 Jul 2018 09:46:37 -0700 (PDT) Message-ID: <20180730.094637.1751168123955659634.davem@davemloft.net> References: Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, dsahern@gmail.com To: sd@queasysnail.net Return-path: Received: from shards.monkeyblade.net ([23.128.96.9]:33022 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728963AbeG3SW2 (ORCPT ); Mon, 30 Jul 2018 14:22:28 -0400 In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: From: Sabrina Dubroca Date: Mon, 30 Jul 2018 16:23:10 +0200 > Since commit d4ead6b34b67 ("net/ipv6: move metrics from dst to > rt6_info"), ipv6 metrics are shared and refcounted. rt6_set_from() > assigns the rt->from pointer and increases the refcount on from's > metrics. This reference is never released. > > Introduce the fib6_metrics_release() helper and use it to release the > metrics. > > Fixes: d4ead6b34b67 ("net/ipv6: move metrics from dst to rt6_info") > Signed-off-by: Sabrina Dubroca Looks good, applied, thanks.