From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 43467C77B7A for ; Wed, 7 Jun 2023 20:40:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233053AbjFGUki (ORCPT ); Wed, 7 Jun 2023 16:40:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40146 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234344AbjFGUkh (ORCPT ); Wed, 7 Jun 2023 16:40:37 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A06B3270E for ; Wed, 7 Jun 2023 13:40:07 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 7FB1B645DF for ; Wed, 7 Jun 2023 20:40:07 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 931C2C433D2; Wed, 7 Jun 2023 20:40:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1686170406; bh=ZbJ7gCDK7c0EFsBKPIYtuF/eh5x1Ur5KVOkMgzp5ZNg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=awsgUVPzialZeW+nS64c6vO8dr+U0EkDoeaj5Sqjwr2sXWu14owr9/moQDbOnLAA4 /O6vt/eF3Bok+KDCGBN5MoxciFGzMiy9crQwRnphARPDXBMG8OR7QloCZYktDn2TfJ /7uOiZuI7aLLk6c5UhrKwg5SsB5Z7zns1XXxzVd4= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Paolo Abeni , Matthieu Baerts , "David S. Miller" , Sasha Levin Subject: [PATCH 6.1 055/225] mptcp: avoid unneeded address copy Date: Wed, 7 Jun 2023 22:14:08 +0200 Message-ID: <20230607200916.155816230@linuxfoundation.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230607200913.334991024@linuxfoundation.org> References: <20230607200913.334991024@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Paolo Abeni [ Upstream commit 2bb9a37f0e194ed95c70603b0efc7898a5a0d9b4 ] In the syn_recv fallback path, the msk is unused. We can skip setting the socket address. Signed-off-by: Paolo Abeni Reviewed-by: Matthieu Baerts Signed-off-by: Matthieu Baerts Signed-off-by: David S. Miller Stable-dep-of: 7e8b88ec35ee ("mptcp: consolidate passive msk socket initialization") Signed-off-by: Sasha Levin --- net/mptcp/subflow.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/net/mptcp/subflow.c b/net/mptcp/subflow.c index 67ddbf6f2e4ee..4995a6281ea16 100644 --- a/net/mptcp/subflow.c +++ b/net/mptcp/subflow.c @@ -759,8 +759,6 @@ static struct sock *subflow_syn_recv_sock(const struct sock *sk, goto dispose_child; } - if (new_msk) - mptcp_copy_inaddrs(new_msk, child); mptcp_subflow_drop_ctx(child); goto out; } -- 2.39.2