From patchwork Wed Jan 25 10:47:22 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthieu Baerts X-Patchwork-Id: 646822 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 DC0EBC54EED for ; Wed, 25 Jan 2023 10:48:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235739AbjAYKss (ORCPT ); Wed, 25 Jan 2023 05:48:48 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50382 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235685AbjAYKsk (ORCPT ); Wed, 25 Jan 2023 05:48:40 -0500 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BB09A56EE5 for ; Wed, 25 Jan 2023 02:48:09 -0800 (PST) Received: by mail-wm1-x331.google.com with SMTP id f25-20020a1c6a19000000b003da221fbf48so965907wmc.1 for ; Wed, 25 Jan 2023 02:48:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tessares.net; s=google; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=iwuYRtkt97pXgnGKWsmcpjqW50hTCzYJA93KmtVKokc=; b=HlBx+O22XMPaRLdCY8bRkkNnoQJ3DAxxgJTt7+b3L5EnG+s9hHIj24S3udDB+1KfW7 HZ0hL+LUIfBGb1uKFmNhFDiNCII356m1bfIK6t0E2xQznWe0FEXZIx8dgzuwgEZeMOwF /hcSGndz1WVTXeHHHppYGMiA21hiCtFhh8urKHlrj/vPURK/VCRSWGO6sN8J/tG2V6Xm mFBS/amTW0N87ynwbWdMtAZPzV0N8GTJy5hwEMNd8fUSAmzHuliy7L+dbWamv14dzCc3 Qkehd+7bhHzWXbkT41nYaeVpbt77GgCDR3zVmcqLTLDoGPfdVietxdIm/74TVc1hkFST l5oQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=iwuYRtkt97pXgnGKWsmcpjqW50hTCzYJA93KmtVKokc=; b=KsmOqqndM/zBW8obMPSs6vPSQo+O/jFMK5upgZXz2J10UZnYbn0xrJvhcBv/Z/brQ8 SrjGDGbSoUYpgwGtrjzEb8jqFwUlpmWyeRTaveQgQD4E57j4WxZ+fwfIcLHNJeL8apxT W4c6FQpTuSPUKa/FvrsZDSn763G1UFRxFQHqckLoC+m8es262mnIhnNxUyu1cQYBRscA YVs1vQsGYr9x3AwEf+a+EGKA8n/Int5D9rd/0q53Hd5Bo9jPzJgJTd32eocEUj9Kskpd BZR1nG5Z3rg8S/cP48Z2THoysEzOOR2PD/9/xbxC8HNvUaBzqykBrRwAASWZL/Y1CE6o l3qw== X-Gm-Message-State: AFqh2krABc44pUBdx3a0vusowHQOZWsL1E32QNgWVaROKsAxIrI7sbLF ImZXriFBaVVYvDaokW02gd7adA== X-Google-Smtp-Source: AMrXdXu1N0sNPouw7E9jGQXXTooMoM8qqp8aPt8Kz6TIc+lbChljM7ALrlyaIpvd2IlXeB30KE+ILQ== X-Received: by 2002:a05:600c:1d89:b0:3d9:f37e:2acb with SMTP id p9-20020a05600c1d8900b003d9f37e2acbmr28251589wms.20.1674643681186; Wed, 25 Jan 2023 02:48:01 -0800 (PST) Received: from vdi08.nix.tessares.net (static.219.156.76.144.clients.your-server.de. [144.76.156.219]) by smtp.gmail.com with ESMTPSA id r1-20020a05600c424100b003d9a86a13bfsm1423692wmm.28.2023.01.25.02.48.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Jan 2023 02:48:00 -0800 (PST) From: Matthieu Baerts Date: Wed, 25 Jan 2023 11:47:22 +0100 Subject: [PATCH net-next 2/8] mptcp: propagate sk_ipv6only to subflows MIME-Version: 1.0 Message-Id: <20230123-upstream-net-next-pm-v4-v6-v1-2-43fac502bfbf@tessares.net> References: <20230123-upstream-net-next-pm-v4-v6-v1-0-43fac502bfbf@tessares.net> In-Reply-To: <20230123-upstream-net-next-pm-v4-v6-v1-0-43fac502bfbf@tessares.net> To: Mat Martineau , Matthieu Baerts , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Shuah Khan Cc: netdev@vger.kernel.org, mptcp@lists.linux.dev, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org X-Mailer: b4 0.12.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=934; i=matthieu.baerts@tessares.net; h=from:subject:message-id; bh=iniaX7WemA+f5FmXFhQpwMPskZ2OOjDI5WzLlog0AB0=; b=owEBbQKS/ZANAwAIAfa3gk9CaaBzAcsmYgBj0QjdHh80nGr6vqKKMF2Ns21cQ6F9LNF4+fGARnIu So5WZVaJAjMEAAEIAB0WIQToy4X3aHcFem4n93r2t4JPQmmgcwUCY9EI3QAKCRD2t4JPQmmgc3bzEA CmmmRHlTlgzud6oeE9klZQXjAG/8elx0t/GIPA7wHH2EQK004iT1piDLDA7KFbf59FjKqe1u0bGK9b 5HwJ0jeOUp1yuZ2bjmhp224fuCwe/dlsle9Al55jQKL5f0V7wM2r6eQCiD/zSkiKUSPJlO/o9uUmnY lh2rtI1Hg1QjOoN/zpLop2TkeT+gg/jJaFOD/fdNGVJHjLn5mgloZnsGVfOxzkR397K5jHuIhqAdyN /2uv0Q4loGyCTBjV8MK+QNzk5uWh3gb8gbDy/bYknm7DYuvgp1bNTP7P7vw7hdPZwhpQ8vu1TLupzL ttDBxwQAGNW2py7qtmU8yE+DlonogGH925IT6d1Aj25NuT9JJljZegjZ1N/3/uEiNKFWZqYXNue+RV jBlnNOVM1sK2aBUK2jAchjbn+si1VndP4cMkVoxsx/w8Mor+E95Cq9cCucNKlVlcL05/4l4vFlUfp5 aQgwIp27S9fn8svwPgdhNxS/dKLkRwaWY48LWagW5xpn30Kru9T5rufLyDtju8ofPCaXCj1z8iYKr/ Cke1t4uOSgxWUF+oXY8DMsl7M2o9uEpJI3gmuEjutwwAkwy9c/HiSEHnjbprdcHxulcYOLHdh3IiX2 g6wo/shmcYvnxUGDQZ8epmYG1dTu+6mBe2KbJtBzeMEbP5jlONGzjjuJlwkQ== X-Developer-Key: i=matthieu.baerts@tessares.net; a=openpgp; fpr=E8CB85F76877057A6E27F77AF6B7824F4269A073 Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org Usually, attributes are propagated to subflows as well. Here, if subflows are created by other ways than the MPTCP path-manager, it is important to make sure they are in v6 if it is asked by the userspace. Reviewed-by: Mat Martineau Signed-off-by: Matthieu Baerts --- net/mptcp/sockopt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/mptcp/sockopt.c b/net/mptcp/sockopt.c index 582ed93bcc8a..9986681aaf40 100644 --- a/net/mptcp/sockopt.c +++ b/net/mptcp/sockopt.c @@ -1255,6 +1255,7 @@ static void sync_socket_options(struct mptcp_sock *msk, struct sock *ssk) ssk->sk_priority = sk->sk_priority; ssk->sk_bound_dev_if = sk->sk_bound_dev_if; ssk->sk_incoming_cpu = sk->sk_incoming_cpu; + ssk->sk_ipv6only = sk->sk_ipv6only; __ip_sock_set_tos(ssk, inet_sk(sk)->tos); if (sk->sk_userlocks & tx_rx_locks) {