From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Dumazet Subject: Re: [PATCH 5/5] tcp: plug dst leak in tcp_v6_conn_request() Date: Sun, 24 Jun 2012 09:41:18 +0200 Message-ID: <1340523678.23933.11.camel@edumazet-glaptop> References: <1340515324-2152-1-git-send-email-ncardwell@google.com> <1340515324-2152-5-git-send-email-ncardwell@google.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: David Miller , netdev@vger.kernel.org, Eric Dumazet , Tom Herbert To: Neal Cardwell Return-path: Received: from mail-wg0-f44.google.com ([74.125.82.44]:42100 "EHLO mail-wg0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753539Ab2FXHlW (ORCPT ); Sun, 24 Jun 2012 03:41:22 -0400 Received: by wgbdr13 with SMTP id dr13so3081533wgb.1 for ; Sun, 24 Jun 2012 00:41:21 -0700 (PDT) In-Reply-To: <1340515324-2152-5-git-send-email-ncardwell@google.com> Sender: netdev-owner@vger.kernel.org List-ID: On Sun, 2012-06-24 at 01:22 -0400, Neal Cardwell wrote: > The code in tcp_v6_conn_request() was implicitly assuming that > tcp_v6_send_synack() would take care of dst_release(), much as > tcp_v4_send_synack() already does. This resulted in > tcp_v6_conn_request() leaking a dst if sysctl_tw_recycle is enabled. > > This commit restructures tcp_v6_send_synack() so that it accepts a dst > pointer and takes care of releasing the dst that is passed in, to plug > the leak and avoid future surprises by bringing the IPv6 behavior in > line with the IPv4 side. I feel a bit uncomfortable to send a mix of 3 patches to fix one bug. Could you instead send pure fix (fixing dst leak) for net tree ? Then, when fix is incorporated in net-next, send the cleanups ? This also clashes with this pending work, so it would ease things if you can respin the cleanups for net-next http://patchwork.ozlabs.org/patch/166737/ Thanks !