From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on2082.outbound.protection.outlook.com [40.107.15.82]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 935F32565 for ; Tue, 14 Mar 2023 07:30:36 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XcO1bVEI+D8Ip8EyHuzJvqocukgrse7maxedOjxY56wdhoaFVc1XIDc5KWtvaPzHM/EEORLRfq3xemx+FaU5YWaSa9S3N4hRNVjFRdCtQQ5awHmRt4M10OQ/2bxNO97U+AAx5jFPCAfgOjD8+DEGZw+kvXPPrbzjJHRxLKEjacqKHOK9NtzdiC5mD74ys+Cp6beTJ1Qg3V1Fs2JkN4diDIVZKJrvxNBFuIoiEp8uKpS7uVfF1F3mEYvdwJsTzkgYO7DuHmAb6DIaIPe4I1gU0LH1zwZ5/egsnCA1f+23CzwOg8hu2YbkdRY9WvpvVrK95jj+ja99ThmHNaauBonN+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=TwajF9lNBsqY7bvbCkMlVPzjyxa5LGUI8Zw9kn7gAm4=; b=TXfZfpw8HOw3cNHMhcj+4yQA0EPjq6Mo/s5lqnuhdZ8mDQ3f3xwjR79FHab9MqUwVrZ4PUTqRbbjNmU5EjfRUn9E0CYxkLmJS4XULgNrwtR2CpxIVKQVeoq0DG6zhAuoNUmo6v1z98/wAJAJf/nYRttAgWHv6NpzdsBfGJIZt/nK4u3vb08w95qZTWZV1+J4Z00itofvV/nVly0DxV0ghrBSutAGhSw6ZQIAuTtDXv8F1Ya3f8jE2plAul3Qsk4YuDtNpMrZwLC3H53oLoc/l6uhQ02BOC7ohRZRN/NRn4bdw2CnrxZcLe/dgSqF/aPS43MfGOBFQuGex0ESXz6PrQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TwajF9lNBsqY7bvbCkMlVPzjyxa5LGUI8Zw9kn7gAm4=; b=RGXK0A1bEdNkg/ccz3LjV4GIXeiB9O+vEvt/m/XbI4iMLFnAuppmwPGmFr8gIR3Ye7/jDAZaQelEe8qWY94OWeq3NL570/yfRDJ1xp1tWnorcapAUIBGiiueOb4YKS35ob84VJqKpjxxqlg4I6eto8dyBLGGgfwzPpIuWUbOO2Kh7JAs+UCI0akV2umgshB3XoFZVVn0z/zueqmkC/Cc2qRe36TMbrC+X5pW4F41R8IS3SSkpDCdCZud3/ceIaL0z7JsqR8mTqxn4mSmpUFhaX0PMDsZihiJBIhyb1tbm5jaAvr7oPotRkvL0CmZBQhhIXuOttNMhtq1W8YAqFoa7A== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:30:33 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:30:33 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 1/7] mptcp: don't clear userspace pm addr id Date: Tue, 14 Mar 2023 15:31:38 +0800 Message-Id: X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TYCP286CA0110.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:29c::17) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: e91be8ee-cce9-4ebe-4bd4-08db245dfee7 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: GCFHUBk0/5ciXbmfho52bxiKfjmOLSGDk02RlPM+buaWGvmRCJK4eE0YqQgr4u9rgVAl3kLgQkpL32shQwTDLDBOeCVX9Xiu+YCFnTkSPWGW0NigYCYjE/dQOBS8/3g1LAJcjn/5MS4jaPwPPPKE/eM/RvcQNIMoziqRSaJm0GUo45g7G3YL+pC9/ZIy0zjB7/dV35FB6ZiDqVomD7xvtnfCWgzYIJIz1KSY9J+eEN2ceT15G3LUTzaXQ/q/xGVAOSVvEbUDYchCYXYLh5Ub++8pOLEr/V2WrURF9jXE6BGSHhMkSG1rjvBTdHAqx7gt51s/GNqRGa70DKAGJhwLJ54yr9OeBA9TEAMFi193++rBY7HLvty+VMNDj8Jfw645fkRr8K6y2oNhxthTMBE2weXrIh2SHf7RlBrJWJUGK/oCMX22BAfnjcXdn0NAUj2tvkH3m8vT+dDEJEtP7F0tyfbOeDba0vL7+ZFK2WSLTo2q4lP8xbZWIG+4iVGz3FUIu3zRyps21M6GTjz0l3t5dVXUWi/1ZMKLAVOui8aiIfn/IX+tbQoFkGWyuR+pp6XD6Z3m+Tu6LciJOOKPH1ls4os2ZNSkbkSco55AxYzZ3r4dh6PNaszD2+YOzb2wsrqTqfLjoKebnIuA/Wjgsm7E3jeJr8hXbzeUrA2ccIkjdgz3wfGC8I6w26F7n8eZU40S X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(6506007)(6512007)(86362001)(107886003)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(83380400001)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?yb3hgrrBDmtHmAql2U0Toxm4/7qeZaCwb5P5KFNv6daYfOlpfCCwCyUgA+cy?= =?us-ascii?Q?U2B425J8ki+FamrIq4uzpceI4X3ASiCdPi02xxFJyeLIJVjWlfrKlMLgAgjv?= =?us-ascii?Q?QFe0Bene5Olb9S4kSwq0f8eyLN34FlQN09LjhUHJVWjALz9+CRDiZhbFqWq1?= =?us-ascii?Q?xDLEtbNd9B6Fc+R2Ds1cHRgzLU9SuLc14SI7tVhOI/jFMcU0P2qyukTtuGxU?= =?us-ascii?Q?J+6IJ+JqGy2RBXRdPs6Gs8USWqf4Wbz6wdwXDLLCYd8vLu+vIA/fbmy8h8J2?= =?us-ascii?Q?r3kLttACv4npv/t5FwGjX4OrO4VwU1pIly9oQNTABnWFGtiLislnGY2HJjnx?= =?us-ascii?Q?CmSv32dmnBgb2dk8tGUKpwOTjoSJia4AGF3g49PNPxByMdkwQ5JIjTNWPCc5?= =?us-asc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JXnu62cFSVyf?= =?us-ascii?Q?/n8SnOwOmG82OKgF6c7uvDxzAogl8Nz6uYoX/XPHn84p3RULqB5pacy4Q35l?= =?us-ascii?Q?h3PhYpoEMsaQPWWa86d0OlNNP1jMQp7q9fhyIohsbPe9U2UWmPRrADXW1G0z?= =?us-ascii?Q?Q7SIT1HRYCwaVZxxcssg+AaoSV6ooqLnS+oTGc/AdxLHUUza3PypTZUwuwji?= =?us-ascii?Q?heE6mrK1WA2GNZbIVGQS5HpdeQ4eOVssvI9tFqBe6+oBRnUjgcWiE3+taHRu?= =?us-ascii?Q?XTjKGvKd47XR/QInpoB7fmKaOeYkXRrWzRcCE1s6a1D2St1SrfpJO9AO1+Cs?= =?us-ascii?Q?Ig=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: e91be8ee-cce9-4ebe-4bd4-08db245dfee7 X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:30:33.8623 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 7g2xgXsvPQFsU1cRjvrAIFUZWpIggFz+LQONGy355oaLgONMvZVp5s/DuS1Ql31n+gw29gZFyEzg4r119/Q0eg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" Don't clear the addr id in mptcp_userspace_pm_get_local_id(), clear it in mptcp_pm_nl_get_local_id() instead. Signed-off-by: Geliang Tang --- net/mptcp/pm_netlink.c | 2 +- net/mptcp/pm_userspace.c | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/net/mptcp/pm_netlink.c b/net/mptcp/pm_netlink.c index 67995cb4f8b8..df15d846e7db 100644 --- a/net/mptcp/pm_netlink.c +++ b/net/mptcp/pm_netlink.c @@ -1055,8 +1055,8 @@ static int mptcp_pm_nl_create_listen_socket(struct so= ck *sk, =20 int mptcp_pm_nl_get_local_id(struct mptcp_sock *msk, struct sock_common *s= kc) { + struct mptcp_addr_info skc_local =3D { 0 }; struct mptcp_pm_addr_entry *entry; - struct mptcp_addr_info skc_local; struct mptcp_addr_info msk_local; struct pm_nl_pernet *pernet; int ret =3D -1; diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index a02d3cbf2a1b..fe4c29a17466 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -113,7 +113,6 @@ int mptcp_userspace_pm_get_local_id(struct mptcp_sock *= msk, =20 memset(&new_entry, 0, sizeof(struct mptcp_pm_addr_entry)); new_entry.addr =3D *skc; - new_entry.addr.id =3D 0; new_entry.flags =3D MPTCP_PM_ADDR_FLAG_IMPLICIT; =20 if (new_entry.addr.port =3D=3D msk_sport) --=20 2.35.3 From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on2047.outbound.protection.outlook.com [40.107.14.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F0C212565 for ; Tue, 14 Mar 2023 07:30:47 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=M6ZJOjS+dSPd1YWuarZuRIIw0/GN4ZHwqHYC8ZhR05uW2wxEKB8anzRXtYXiePPF+TbGcCerwXNbUW1YwuiCKcaz8KquUkw7i84pZ5waaISg0pVNwhLXlGkkCoyigBkUntBpdA5e2QH8B9djOSNmgjBW22dR6RZ7iHHN5hfmkT+XcoucArZ8ARqk1EXVq20CxIOsUdr+CbTtjDzJmzveQwahjXzZVth2aHrbTW4gr6I6k5g7YGkG0RZH0V5ClaEnAgxE3BEHam9EUU0171xZ3RgzmZ8B+Z9ESW3fLBiKY+cv6o+j/Ox38YOljx0WD/RxfJ3kd+6yCB7yAdbu2nYzYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zBhtd/ANFziG0QmGj3k4rTed5mTyRh/ckWhW4PnSemU=; b=h18thTB0XekPU+lNGCQxMG8KTGA21ixTie9aluOqSiI5bble9eZ/SxfhiWsScR8wgVUJDmkLnLWpn5wFzrhHQprb97TXmnahT+Q/veuyVg9uvzkBsleahob53UARrzPOBibbp7tzX3z+evZmHxN9Mf7DUgE/544tZQsfaMx0BfAew1iInfBt7CYJgfpUkk1zG/bLvUDBolYgbsAteR+K0exGZguCBCw9aRqS3k4o7v01iQ+yRiVY0xBVJLczIJU+6+NfZ03ChHYyUa/smv0T24CSjqqAxtt4Sk8KvJVdrsJO6QGS3FGt6NPjCfaD+xwZkm635F7a28/djO1KrOSi1w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zBhtd/ANFziG0QmGj3k4rTed5mTyRh/ckWhW4PnSemU=; b=m96t8Jq/iV/6qGpeBrtaYxtUWnvgvDAzv2tBtN8f0pnVIOzTAiOpZ5MLCJXNE1HxSLl8IXqW+KZgqT1gIXgYXZwdgdorFGgSojkCs0Zm1j0pjseBpmhxTDkW4AY3FVl49m6ojuQc5TSBXTT7NgkdY+B4/jlhi1ad5fkrswworfBbQcRhd93lw71bRRxPnQRbtDEpMP+ARqAX5slniWdBjkMkQ9chtknOsPUbf7pGyXBHDLsO9vtL+Poc5Cpnc3nEzrz7J2SdQ7qjUeWy+IlfzrxU8rp8Qfx2YNr8+pYMsYzjOvkXIUSAAjJ29QHu4kWO7tqUgTy/onpPp21R/IvylQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:30:45 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:30:45 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 2/7] mptcp: add addr into userspace pm list Date: Tue, 14 Mar 2023 15:31:39 +0800 Message-Id: <7f59cf86d68c27fb9785d4a8d84cbf9ae1437d3d.1678778977.git.geliang.tang@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TYCPR01CA0121.jpnprd01.prod.outlook.com (2603:1096:400:26d::8) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: 359052d3-88bf-4a7c-33cd-08db245e060e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xMDziHovWUzckexT3hZPtN2xFyvfCAF5B0NvLR7LnUz4/Cs8LhnW9VFKtOWf+2XDIvTKmrajaAaqJC5CJiohtcsgdWYIn9NEQXeJAaLSaInjmGHoXN3NaG0xJz6fUbjI+Vf+rwbJgKRH1yCX+ugoj0W55bEWIOnEvlpFKb/sXRLC7o1jpLDYv77WmOZOpnmBEYA2dGDmoAJzeObyK9ab/7GIwXuuTyh9l1TVidtpu52cBK7WJGeYZC270K9p+Z6vcidD1UUXjhvJ6LmOwsxVJpZWKrko4Tl22WfcZhdge7bOJ2XlyVROctlJizGXku1cvJUPrP4tLJZ0gpwb8FcbOmsB4yLyTLAvedWAGVFAyRM7uYQ6AULLHj+2/pKA8HJ6qAM0bep6Cs8U/iLrFmLhjt+JESknK2lqk+HdAafH0b6gzY8CdcvE/EiUiXDjYJhbFpL/0k9wBKiEh/6jPaRTQRX5wSnQbFrmNfrQab4b5Saz/LDXj2xtDC+zs1L5kSNg5xcpaaMXvtcJQokj0RtPhDSCi2lXKGedOzc3uFt1UD4hbd/OxZBu7VkpftPfGe4C8JaYxIHGmankSCirT1dWFeq0FcYrlcOl4LdPn6YPj/0oLOkidRmzCqqlcHUjhFADTSgSx1msrLoqW45JEXGclBzTLTzu7P3wX4Qw8p9HeZoxygCp6wJtCuD+IdV+KnPK X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(6506007)(6512007)(86362001)(6666004)(107886003)(4744005)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(83380400001)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?HPIM1vSzcH68gxbQMxv9iDvbkUK9msgJwPd521IJHGusenfhYYTQwZ/mcbQ0?= =?us-ascii?Q?jIyeee5pHGXHOVINhwfemneY+nAuSkcKRiWEQNuYKO9dWonvEySL8yF+Huwg?= =?us-ascii?Q?01az3878lHbvdd4sOt0sr+jF9AOqmJOtWRkPZMxwJo2Nd1jTK9jjpF4IDFeF?= =?us-ascii?Q?U8UH4tCNWVzcdEPoycQ31A8xhbxXdOMhFo1fMDRurmFCumbbrgATOPsU4/3M?= =?us-ascii?Q?AIYEH/DTuFNbWkUmetMeq8aG3gqI7g2fpiuTYKdCiokI7X2AAPQxvhcNnHsV?= =?us-ascii?Q?kkAwARtKGoRVk2hTf+21ttjjsGb4y4pK/9+qxZfVTSMJ7TGtk7EssVyv3lMr?= =?us-ascii?Q?+rqNruDQKA1aTyz7sv6qsctiQC8klOe/Coi3/S89XevpStncwvyQlGk2P8L1?= =?us-ascii?Q?nJbkL+eq37x3Qui3yuam7x7Bseb9zX5CXqWcjVGZ36r6A1IdoBzxmiovktQh?= =?us-ascii?Q?Q6w7uOMDGESFGV5szbIzR5yXvhJfvYFumT7NAWGmz+jZlUrpYrxMvVHkXJkv?= =?us-ascii?Q?+sw71SQfpY4jUYPfhNlhgkmT2gWR//7DcOVcw0k3erdhZep7mr+Ld817BLT8?= =?us-ascii?Q?ldsh4b5AiPx4LIyUvL7tOLlQx7PYSMnHgmeKc4oHiYhKlH7lLXM4plqq741y?= =?us-ascii?Q?GMzu6Qd9FY0XRYwAQGYichZvnaIk3epxafR01T+HwDqpnwfesoxewtoA3k6E?= =?us-ascii?Q?3oWJDCcIUXygUs95Ik0jAQayHcXo1vTLBcZ7ub5qSHXHcn0iPiM5gPdP4CIV?= =?us-ascii?Q?MlVY0w7S9smzAEkG50OCpLOk8pRkl82yoNdwmds6F3n1B1qDGwhOaeAayTBr?= =?us-ascii?Q?8Pd7Pb8NaBcxvpmrf4Z2+tr/No5Q0VAXfmHkeMNMGn4uhIN5rgIAo/YMYRil?= =?us-ascii?Q?GVsWHE6WKFpmfLymPePC/tkoSgMUeD92kiEaJX1ffGIKL6OE9XZOdl30YEZ1?= =?us-ascii?Q?EptrPRGbIgNm8C3NjTGtyCrw8Rvin142qEePIhNrerK/cgc54Hgcd7NdjthJ?= =?us-ascii?Q?c3aBx9zNQFdV3r1lqw41l/DM8Is6FV293mclbP6QoJkwPFbp1C86QHDm72pN?= =?us-ascii?Q?SxrT/Odicq/eLRaeEPO6+GorDsNd84eeV0r9ZdYm8jGNCo9reTeym5aNjD8f?= =?us-ascii?Q?+fcJwECYaML+XMO+Tsg9anwlfR6tp5eBKeF9XLhdpqHypW/MtZ8zYS1lnOkN?= =?us-ascii?Q?e1JB9WdbC/3phDDNhm28h/ibakaY2f8WqTypW9PaBM5UUOflgRV64+hwtgy7?= =?us-ascii?Q?ChJP206MplQHns8GACqt0BcbuDP+MGBsI/TFmAqTNI0dKi71qHiKp2qj7TOc?= =?us-ascii?Q?V471SYslT7s1fqeYHEtQKfWmfoldMDv9oTg3Oi5hwo5026B2vb7qbP0L58rn?= =?us-ascii?Q?6hkBKDhLwKy/zOmQWx5ujVym2qMwWFxNI7Fi1ffFlWp+MIP7pXrqM2rbKALF?= =?us-ascii?Q?uqToPBFm2g2mU1OVIRlUG7PAB5ol0P5sC0vpnuFjxLLiO3SBr0ZvFAiUNlbE?= =?us-ascii?Q?VN5ux1CSD1xPyoiVFQOGPGIz7i9qrj9qnoSimO1OU5t98qOdr9IxHaat1z/0?= =?us-ascii?Q?GZ9NwTxtirscddtpLybq2e3k+ySEuMogNFNmtiTKFIEGZUFkReVFS3Sjz2oO?= =?us-ascii?Q?/Q=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: 359052d3-88bf-4a7c-33cd-08db245e060e X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:30:45.1583 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: gYryL9o2kB3PQvbT+Fgc4e4pN0hA8O0YZlxFjUj1q5UL47T5Pfwi86jVSvqHsOjTKGto8Q1utjv/DS8H1bTpAg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" Add the address into userspace_pm_local_addr_list when the subflow is created. Signed-off-by: Geliang Tang --- net/mptcp/pm_userspace.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index fe4c29a17466..49f41a040485 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -301,6 +301,16 @@ int mptcp_nl_cmd_sf_create(struct sk_buff *skb, struct= genl_info *info) goto create_err; } =20 + err =3D mptcp_userspace_pm_get_local_id(msk, &addr_l); + if (err < 0) { + GENL_SET_ERR_MSG(info, "did not match address and id"); + goto create_err; + } + + spin_lock_bh(&msk->pm.lock); + msk->pm.local_addr_used++; + spin_unlock_bh(&msk->pm.lock); + lock_sock(sk); =20 err =3D __mptcp_subflow_connect(sk, &addr_l, &addr_r); --=20 2.35.3 From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on2054.outbound.protection.outlook.com [40.107.14.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 977972565 for ; Tue, 14 Mar 2023 07:30:59 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=B1oP8gNvhwZY8a9/0cyznaYZFt4HiZgI4MC5XfrdNscr34hMjvZ5PVrlWKpr6mNpX3C5LSQjOwIPCT9CidYmegwj1Y4tOR0bsvHuJIaDBJeVO6GA/XDAImOLCUrbA4L4rGqKV0bU4nW/meao9V5sEn4TK7BTdzzMqGnCPYYbRtbScC+wbhQYjKsYvciPnrMcKkZDAMgBJNUCmv6uKs0Wng3jp7+Rz8kRNgF7QIrlXEYg7ZJNeP1gCGyUQi0BXaszj1Un+2S/S9hfUVGbz0+KmammY59njapvz+2VNh1b6QUnfoBeGC2jUZIlpEQDrtptgjtcw+02vhlITz3mdBYf8A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Ew2h5gGi0lr+uyGAwExHNoaYC8uKjoobDnt5qkRue2w=; b=Ucuqrt/lWs9ogBIBy5TsVbJA04weLoTT+lZSMSGqpMzg96zqgkoADspZvUwoWyHvdaVgHtehESN+uL3WG32pLnbPWfsGvbv2hg1C/wxizDwcHJady90z3wxNdqLhSNm3+qrhkg0EeIh0aZ3mIgQ5LUp5Wy09xlE7EYi9mOoSqsfvweytZVJsA8Eli3xXagqbk/UYEx2fqVYOuZFDmDiVYqRznAfhXmIMldGyASbe5GCC5USNX0mn4VehkLiVqk5UGegNjBzPX++rgsHwcdg9cvNaqRbyQY4YtJozRn+2bdPwVAMIvc36jagSUkS3/WaM4/I5ELV2tA/J5+h82KhwWA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Ew2h5gGi0lr+uyGAwExHNoaYC8uKjoobDnt5qkRue2w=; b=X5aoUmPOJiHWKz0mHyKSAKRpKa+mx6TkUkTWobNh5yaYhqYDgV1l/H+Aj/VHJAj2SVlUvovOSHbDuNULTQOuZTs/N5oMX6R3znGXrhwWBnh0/Ag4hP5UWsfWdFh94Thy9USNskBEvsLsDgB6JofSbyP5VRPa3JzrCKzxBobVmpOPCtL3nuf9n49qNaCdhl6MJzsXyIOmJQCdiGwl7ZLMRKDiaSFSIAYG6uYZATadP/HwQbeVIfZ6WPEOblhpLg5i1z7uMFGPaEvElJHYwL5SVIUsiiuKQEQJBycRBbAifvC2qFffSqnCGy86vkcE0yNHNWVXEpKD7/0e9L4lDdKZXQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:30:56 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:30:56 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 3/7] mptcp: close remote subflow when destroying it Date: Tue, 14 Mar 2023 15:31:40 +0800 Message-Id: X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TYAPR01CA0042.jpnprd01.prod.outlook.com (2603:1096:404:28::30) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: 8d578d46-e27c-40d2-bdca-08db245e0cf4 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: gzgKiybslc+jBT+Km5lfD8qt7zM4EWmBMZqhqIXSbqq43NoAPTAtEDLA9dBgqBdU3MR6a7fw+qtl1GZthNhfQgVCnfZFdorcZofg6mYWpoQ8AGf0YPsGGjssNtHZN6N3Ix/KgARTxfKpL/tYqVfFmK/d89Xf1I6/IBGvERaEIu5zOr3eY/XPiwHZRMFtycgVS8n6PzB/K5+0VrGjHCc8nnoCkhxN78FFcB5kZnHSUZ9paIzuxeA5ZWJa4MDZ66JX4/fIW8eviibsTh/q0A2pPuG1jVb+XgevTh8g1bHQoop9dpkBa7+esvzzmZUgo8yn4G/HVNVg+ekMH6X33ZxrDQNxlWS8WvVCxns2I9b2rZLOayto7X20IeGKRO22r0Z1j3+wlUX1j2ZCeIKR8swO1zDCOygZ5CPmKANXBaX9O+FwDEwr3xjL/VuNO8xVSgHUVKR3HaiMs4zNkCCvqhKZZm95pTVpbwWISJejeGyG2LoTbITfy9hv6yz9XKOldpox3ICWOhD1TaGbntRXMPplmiYAg4P1808FXjz/u+j1poZa15Kx/xCuQulu9Rqy8uWl5kP1xtLPFcPlZnuhuIeMfZnOMIt42fI65Gu/pRfuTlqjnz5V9LMXHAzRsk9lq5GY4lqo+aFEuB4bk0Y/bLEDoZxSzi/6ywJHkMXuhZLw3fAi9FdkODFGApLpcMtf1f+N X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(6506007)(6512007)(86362001)(6666004)(107886003)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(83380400001)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?GU/Mk2TvbeBTgqj4Q7cl1kcbLO83JAz3gGnW2he1J0O6CkrCPXDFTLx6veov?= =?us-ascii?Q?xy5DSGTWcXqJwjwvqZaGCvLQNRTIJwxd8fNK1rR1zhaX2+JATaPhQVKXkfxY?= =?us-ascii?Q?XE/zXpU3PAkX0T4DmPiMtg+XBI1qMnRNF3MQA8ZZB9Md1CDFPVC0SI7Obcm7?= =?us-ascii?Q?jbQVxZ5Ao9WPKwzzm8k73XzlOBYlqdW0k6k6S8tW4ak1K90TB+5l/j4z28XS?= =?us-ascii?Q?YtCx27mL1kO+i+++bPzuA1DUxZme3GPowmo3XrgSuIHLbytda2yc6Z8iOmMb?= =?us-ascii?Q?SjgD9IyhEXT3lAPchwwNUaapU4rmYq2jYLQC5RzC+XeqvkBFhiS0xmMo7TOu?= =?us-ascii?Q?y8JQO21SBchC7BXhV/32aOdwc6vHB8NXAdQ+lexHbpxMxBXDuOLlfS6eZfW/?= =?us-ascii?Q?ZluvElevz0sOSMpT98KqF9culY8oFOPsP8j46/IrPdePQj/DFM7A7ZGa5Xln?= =?us-ascii?Q?IcZo/VolweiTy3Jo779V13cz6mWOpOaRnF1VK927EhrjxfmmjwZl6kJNrbIw?= =?us-ascii?Q?dT3c+Ublf8cKGxkjXA11q+qvuCmxjr9n6HKOilMCCNob0ow5H2N5ye5bO4lF?= =?us-asc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K1tu6ol/RfUIo68H6tjOhKRXcm8awR9v626f53?= =?us-ascii?Q?hkqElhVqoMGfFNBwAuze85k25k6qp//QqMikQgsNPk8Va5OevjiPuGE9TF/l?= =?us-ascii?Q?Vd7rAYlVZzzPodFE4mylIKAuhCHsZmTOJXSje3oUTBJfuae0BOuyT2PaAsyR?= =?us-ascii?Q?GQ=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8d578d46-e27c-40d2-bdca-08db245e0cf4 X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:30:56.8448 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: sXlAuVy7NRW9/arAmexwydV50dKD930s5iYokcSo9vs8Re388/zix0nz5HEg/btbC8YqAqjvIfwj8NheiNV+Qw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" Not only close the local subflow but also send RM_ADDR by invoking mptcp_pm_remove_addr() to close the remote subflow when a subflow is destroyed by userspace PM. Signed-off-by: Geliang Tang --- net/mptcp/pm_userspace.c | 16 ++++++++++++++++ tools/testing/selftests/net/mptcp/mptcp_join.sh | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index 49f41a040485..8b077564e394 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -429,6 +429,22 @@ int mptcp_nl_cmd_sf_destroy(struct sk_buff *skb, struc= t genl_info *info) ssk =3D mptcp_nl_find_ssk(msk, &addr_l, &addr_r); if (ssk) { struct mptcp_subflow_context *subflow =3D mptcp_subflow_ctx(ssk); + struct mptcp_pm_addr_entry *entry, *tmp; + + spin_lock_bh(&msk->pm.lock); + list_for_each_entry_safe(entry, tmp, &msk->pm.userspace_pm_local_addr_li= st, list) { + if (mptcp_addresses_equal(&entry->addr, &addr_l, false)) { + struct mptcp_rm_list list =3D { .nr =3D 0 }; + + list.ids[list.nr++] =3D entry->addr.id; + mptcp_pm_remove_addr(msk, &list); + list_del_rcu(&entry->list); + kfree(entry); + msk->pm.local_addr_used--; + break; + } + } + spin_unlock_bh(&msk->pm.lock); =20 mptcp_subflow_shutdown(sk, ssk, RCV_SHUTDOWN | SEND_SHUTDOWN); mptcp_close_ssk(sk, ssk, subflow); diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testin= g/selftests/net/mptcp/mptcp_join.sh index fafd19ec7e1f..506120401abe 100755 --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh @@ -3123,7 +3123,7 @@ userspace_tests() pm_nl_set_limits $ns1 0 1 run_tests $ns1 $ns2 10.0.1.1 0 0 userspace_1 slow chk_join_nr 1 1 1 - chk_rm_nr 0 1 + chk_rm_nr 1 1 kill_events_pids fi } --=20 2.35.3 From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on2049.outbound.protection.outlook.com [40.107.14.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D5C202565 for ; Tue, 14 Mar 2023 07:31:11 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WJIcGO61dcDVpTSXJxs/l6b3lkZDFQsEkZUh3w6uT2KnhOxcCqisASYp3N6gsQbMPvWAhCOe4kQgumwATy+jwbusTe5L0KvjA0/kon5Sh/eBLTvwUGTo3pu5GGUpHCX1ZdEHGAbFrbtlFevgetk8HxRNt0W7DyCRxtte4GA4hBqvLMuV+HwRT/SMxMC1sSrpWTaCT85cCae2M1MjBjjvoNt3Ut28tYziJWPquQVo41SNP9hNHbQwOXjG/2VK9EUetCOgfOWssaCc7xElp1Pe8Vi3g6wQmAmK3VBkmYX0rDHb0FCd2+LTYG/HrQ/Jjb54RHr1OrIvYxMww2fCweel8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=2kO9CUzCdHTgwfZg10CyMNbz9v8I6qsypVebY9uJKQE=; b=SrvEV4ganTSY++WxU97MrI8dyG1u7AafozaOCCPj7fzwXiugR8ndu368dEe2E7j8NKrCKDJZLqsHtj4tJ7TD4F91l1uyA/NyYZp6si4rXks6eU4zLlO+uzFvOdIApstz70DgP0IzKHXHCw+wKPntubgN1jIBVqlHNoutJUfFP8qTDqSXv01QiJJQCnihpp5kOG8pako4DCY8vyCLXrckxu1XMvFOPH8F8WXc6IBEnheAWel9b3NFeFoSqRIRnelxdmpV5tAxoJgUFDp+P1xJiqV3YnsDGf1/cD3aI2JVTGEcdYMmYFsl4kdEAFRCvk1Q5qi8NsJTSaRyEZzXB1QxSw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2kO9CUzCdHTgwfZg10CyMNbz9v8I6qsypVebY9uJKQE=; b=tvdv8hCc5F5HL9JCEM91SbnrZqDfMkjD9/YDIUGOAwX/MHrdAdicAZKcBjj6MdorHN/+/X0sd0tBsMvOCsga1oStLHNaLNBiaTKrekF772QNrUz4bidkqeGguuZ2LbB0EqAVAKmSh3SpOCO/lROCXpTE5ivGFKtOgjX2CnBmUl05+v9c0Bmp3okTkA/o/VCDyuWmZXzsFO6rpzVCaoP+KZ0qxPxzSffiiqTjUhird1rJHK6Y3BmrCCyP+WaGwZCKjvH5+uFPXqo9zSAh92/vyKVzaiGLDHGfuA4vdpgSc8lrrb8HznquuNPflJs3pxqK9W9W0Guk6afW0ksg4sviLA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:31:08 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:31:08 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 4/7] mptcp: increase userspace pm add_addr_signaled Date: Tue, 14 Mar 2023 15:31:41 +0800 Message-Id: <498e1cd7f935d4c0867fa61170895539606989cf.1678778977.git.geliang.tang@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TYWPR01CA0026.jpnprd01.prod.outlook.com (2603:1096:400:aa::13) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: 1a722d04-e5c8-4c0a-cf03-08db245e1403 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xIYzJHOrlxEhWH2x5wHjnyCmKIOsAiRN5t2O/PANPy6NHxsrlCMgREL0bs104W/lDMkK8J6RYzGLuKKpO494dKyNSFxJl40jbisicH6S+tMLUmwKVJhMqLfZ+iOYw/JOM7wLmCZ07QYYgMtRK5PI7beEVVfJLpkxzZPNFCTzqdFgz2zBPeI6tat3LLgaEgAfHvYjV0R8IX/ara2v1WrSuHTYvjDbeAGYt+vAjOxRJtXqbltQjMgsWRUtAM7k7J8COUp8bNpgsipaK/Jhw4lOW99UjMB5Ghi4E5ia4RIxEN7Ft5NcT6yXxvvR/GIxIWgjXp0clMeej5kuxH+rWshx/NI/QYfvu73ICgGvVopIzTSc4F66lkb2Z5Nv3eIHPVxcpS0wR5+eSqmQWtKYZq1+hfdqPzn5ldgX0HwQnVSW76v6EHRZr4wUKMSQj3f0S0j/pqfjbDawo4TUnsP2AaDFEXOEkj9xy6pWhvp651+XlYz1BTmoikoULPaDiDcEusg8Ra0JTS76+U2thkEx4K/nDNTO1BicmN/eHacBJ4H3SEBKOhmjvkYOjutJfmMYzoRafD+gb6KV505B5rZI5D42pcDq0mOAM/U0ynculjNXL0JesoLSGE86RVVY+8hXrbidZBs/wWqDDUsfETB9AVncuPR9qejlXWmBIpGKNRX8CoHdgeGky86uN7hfEnbm2GmO X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(6506007)(6512007)(86362001)(6666004)(107886003)(4744005)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(83380400001)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?a1CTPm+wdS1eZwLNYHTNQYTNVkMcbpmEWP1Pl3/CtryPzhpGFjGpn0y2qEsH?= =?us-ascii?Q?JhUB1tI4LP1hiW7g9yYGScFsDuOJLbJsZvneByuGbnouDS7XY3D0I0+xz1bR?= =?us-ascii?Q?+teseOwm1QyiiH5OFBy9M1jKm59m/wPwneUhbGKEAQ2MLRiz7E+3IniklIXV?= =?us-ascii?Q?8YhK4/TB1SkTHqPAyg/XkWyHY2rDaRoD2y7RlOc6aq/qjbX6ZVNykICY7fjA?= =?us-ascii?Q?PrTu+7ZrIu4rmnmcotlaF9GZx+xb0wGv6Y1fmEarsEfYgxobGjQlXfvNkXiC?= =?us-ascii?Q?wtE+gMSJPaiwxCJuU9h3KmKPN1xDbVaVxDWejRDo234DmA1joPsQwvp1+E8N?= =?us-ascii?Q?MBvU+KngcUreQFbkKSiCCxLb4czBBE7WbCOsluA2ZSNMYgvMHfJ2uQD5I3Xg?= =?us-ascii?Q?K+pYsUwOJXGe/U9qPupTpWhOHUdXNSM8CD0d1qyntUBCoh57e+uXtiNiXnXV?= =?us-ascii?Q?GqAnbPZzzU1nQSn9qkpI5PKjB2RqcCvINxfZj3/GjdX5rMMDZiHpn3GnWQIx?= =?us-ascii?Q?uHEU/yrkvcRPkWAnvb5c/Wq3FnWgAhwOyRTjqvN4E6MJDKOpl1tCl9NJT0PV?= =?us-ascii?Q?0FwKvnZg/U9ikqGq16TzZpXL7ycIGYEbfhvJVxw6ONlBnbYmBMNME09RHquJ?= =?us-ascii?Q?MnAgchFdaWwFtun8DDxfvcr75ascyQeefIdcZukR6hoTo3VHfH5+FyASW+ne?= =?us-ascii?Q?2p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wT5/Xsj?= =?us-ascii?Q?mg=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1a722d04-e5c8-4c0a-cf03-08db245e1403 X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:31:08.5939 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 7YePiLUCMbStS/kn2AqdXKKTqLUm0FWoXveUGJJ0qgvuecYwBhemnON6P7eJ0QA3qBesgTHvzOW6zBPKjejvWw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" Increase add_addr_signaled counter in mptcp_nl_cmd_announce() when the address is announced by userspace PM. Signed-off-by: Geliang Tang --- net/mptcp/pm_userspace.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index 8b077564e394..09b4b359d960 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -170,6 +170,7 @@ int mptcp_nl_cmd_announce(struct sk_buff *skb, struct g= enl_info *info) spin_lock_bh(&msk->pm.lock); =20 if (mptcp_pm_alloc_anno_list(msk, &addr_val)) { + msk->pm.add_addr_signaled++; mptcp_pm_announce_addr(msk, &addr_val.addr, false); mptcp_pm_nl_addr_send_ack(msk); } --=20 2.35.3 From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on2080.outbound.protection.outlook.com [40.107.14.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DDC962565 for ; Tue, 14 Mar 2023 07:31:20 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=goOMeDH5JVUvx7/mGtCaQffFB0rdqBMCAEa/XS8XAA6usNtBisK2bNfNOH3t0GHmjOjDgURPWZ+2JeJer4EcBgkCi4Wtzm1EZUhYCWp7PDwL89/RJGL4Lip/Zl0/b1UnPu8/ajK1y9EZBOhImZ+X6JzLwxNZoZuDn34K4tjGbEDE8Yeji0J6sXxzWWDM//gZeAagHwokp+cyIEgzQRHhCiIOfxiXulqCjYpduZNGs47I753dEGNyRMKeIc7ebclzOhxy69Yp8mRIlLd1gnw6T0S+m5xAFgSaLq+62WGJ62YHgnIWOZ9i00sGCEMcZakW6WIbOw5oqgisOCRyRc0itw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ap3GzzO3yAIhll6ZLPGy8SSdQ/TxCnhpuWTO6TKXXug=; b=cZwbQpNoDzVVjtgrCRAc3v0+xEnRYFkgcMyhVp76NVedE2Y4AmXw3JgjRMVmzr4Owk3cxsutGAf6UYerz47wUQjgHIr4prXWCTgpCjQ//97P+P1OAsOaQxiaAmdzSqxjLbepP7nMHo6NOBzU9mcO1sBcQbBWyW2vLZrk8oXn6zB/sgT4rQmu0laHk56DcQdLxaqdWfAdhn4kEMrjHqSH2p5stLMeNAEUTuk5epgEEAH7xJ4s1J1TI4T9cXplRXAG0wOhrQ+96ebnn55xxEOcarQPeUgh+QBFg67vL+o6y45T162/Q8X1B5W0ewGtfqUdznnEzkKYuiBTYyRLfuP/kg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ap3GzzO3yAIhll6ZLPGy8SSdQ/TxCnhpuWTO6TKXXug=; b=gqnLhrSz80PbdRQBc40t5NKy12bDQwUP6F/yIUEPnSXlEwJPKIsiuJ6J3EQ+sOdLq6IdElRDJrZSFtu27cmccrceV66skiKIw6C+YD+ke4uimCJwmKOVj8TXdklWdbX/fSF9KH7k2HTpJQwUCbiONDulWpcAkwloOCY7+a0dZaof7LGw8tbbndcgy++AGAXLKFuI/kBwHbCqdRDXirQERdF3eu8oIC6IBquUaF90EZs3waC2qJNkF4FnvuvLtX8s53+GDbgL7KN3Kv3vThIjXVgjbr2FeLdmyxAtbI7Ee8AX/1bXE0rcp8d39siaceiFEOGeklmFIgbXg/CIuOi4CA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:31:18 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:31:18 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 5/7] mptcp: update userspace pm subflows Date: Tue, 14 Mar 2023 15:31:42 +0800 Message-Id: <07483b4044333a3d2d6de1e5c06a32672c54a24f.1678778977.git.geliang.tang@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TYWPR01CA0029.jpnprd01.prod.outlook.com (2603:1096:400:aa::16) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: 75418b3d-c3b0-4427-6de4-08db245e19b4 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: cM3SUCY0UXm1e3vRq92MrrOHVfuyFZbrUApG+PMWfEYK8bxKWMEEbKt/emIBUsDNFMOxxSaFhm72cctgUQAgyxiQULGMVn798HQioZ1VrykwU1umO7L3RiOmr0AiUkLtxP+Pb9EXMHd+k82lC+bDV7veQ0df+0+SRIovsejbXBptB+z++1RKRI6UWf6AilonrSOnbjCYw7TQnRRtFHtyVfMLzcUhsY+nWalwtc1dyxgCZGEBxWvBCLgW6W9NegB5DJRx88bjWpdSyWe/F1guO9nbv+LZLV02UN5oxoIt2xcW3Mw37Pgp8XM4+b3zXTYbfdIfx4kVn1mlzwh9cCT3ZrVVI6FhYazbg1yJusg3md/ZnY1SynqHa2xcBqgkQh/hcGPZ6tNYaOpDhNzgwMUJsovVvrXNFojqcZq6r78EB8KVRg7Gqkc+oPZPHX5jPpOb41XasyTg5yT3Zouz9P5oolnDYhC4wprcT4W66jNInlvxHViRpZukBW2R+NG205XpUJkD6bYFoaR1GEKxKdyTVQrnGAshoXjdhfRF1+y4jrm17rzJqQQz91Bcq3SXmNX4lfAoX1uOHMfSa/u4kVJm32xA9gl+Vjza9bfs+ANJdzDpXV6IzoYUBL2kMBy73ybUdZ8lw7zVuvReD7VfYDtMMfAg0gaQ2hK6IWtIT2urB9HTiq3P4OieW+YRWV2y44J4 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(15650500001)(6506007)(6512007)(86362001)(6666004)(107886003)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(83380400001)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?ZXZlA8iLbVAA1xwp6OD0quMIvHyYHC1O5rys+A+Csgj0G92GUSdtGkzfZMpC?= =?us-ascii?Q?tfCXZgfwPTi2jAV5uoryeoiOBgsOxvIqcdh4ftgl4bXkn2DEqTgXusRuMv4A?= =?us-ascii?Q?a6qCGvbqO7XiPI2yQXiOkc33tu2PyYVtV/MbVE0Cc2jdLkiMGqIPjJp6ceDc?= =?us-ascii?Q?Qw9xrDWk0s3JkZLOcUW4V/288V3qfnGhCdLLs0apCguDDWRB75T5OmPuLbxM?= =?us-ascii?Q?7xVrZTQAvcgOVSc+rptaV4PwwEdEidWaFa2hzGj4XiggwLSU+u9hyCVRO4xB?= =?us-ascii?Q?33h0dTASx4GSWFr528FFo9/scNgXMvXogyfuDvn2ZPQSqjl+41vJkSgn8OhQ?= =?us-ascii?Q?BLd3cne6dJ3uaBv8gSNcx1w28mWs2MVVfq3sBWqev5mew+0O8R2tkVME73Ru?= =?us-ascii?Q?J7jFm5jMeaP20yMubNEp1JZjVMpJ8Hlrqpd6Qlzm/bf6J2OvJfp5GYHBKR8O?= =?us-ascii?Q?Vcyp4tBcIiF1C7/rsVWfGbrR0jMe0u9SXkD+fJ935CXl6vFz2UazrE7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emyjhByuEMWjlLAoDEmYlt1YdI5kny+QkrdBSkyhkz?= =?us-ascii?Q?RwOuO2FDatZ6y3nZYY0sUF6sovK0qSctjgAC4d3PsYTS33trx1rpDxa10qxN?= =?us-ascii?Q?itzbpglV559asl8/cyVGmSWOUux3wycUzPAt6tl+ZlVEoM7aFtT8MgWoVJWa?= =?us-ascii?Q?+zyBcJ5+ELk0IuR75KZJIGYgpU52QGicMlxvzJNmWrvEJpWMBOOGBK4op5xY?= =?us-ascii?Q?rA=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: 75418b3d-c3b0-4427-6de4-08db245e19b4 X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:31:18.2025 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 6PR0UMd43AOggRMMRrf6us8JbExI/0MHBPzxxClDnSQOpfBbf0Xk967uA+zMokMUFVhCw9jK1wcL88gflVnOHw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" Increase pm subflows counter on both server side and client side when userspace pm creates a new subflow, and decrease the counter when it closes a subflow. Signed-off-by: Geliang Tang --- net/mptcp/pm.c | 21 +++++++++++++++++---- net/mptcp/pm_userspace.c | 1 + 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/net/mptcp/pm.c b/net/mptcp/pm.c index 4ed4d29d9c11..bb01f15d8e0a 100644 --- a/net/mptcp/pm.c +++ b/net/mptcp/pm.c @@ -87,8 +87,15 @@ bool mptcp_pm_allow_new_subflow(struct mptcp_sock *msk) unsigned int subflows_max; int ret =3D 0; =20 - if (mptcp_pm_is_userspace(msk)) - return mptcp_userspace_pm_active(msk); + if (mptcp_pm_is_userspace(msk)) { + if (mptcp_userspace_pm_active(msk)) { + spin_lock_bh(&pm->lock); + pm->subflows++; + spin_unlock_bh(&pm->lock); + return true; + } + return false; + } =20 subflows_max =3D mptcp_pm_get_subflows_max(msk); =20 @@ -181,8 +188,14 @@ void mptcp_pm_subflow_check_next(struct mptcp_sock *ms= k, const struct sock *ssk, struct mptcp_pm_data *pm =3D &msk->pm; bool update_subflows; =20 - update_subflows =3D (subflow->request_join || subflow->mp_join) && - mptcp_pm_is_kernel(msk); + if (mptcp_pm_is_userspace(msk)) { + spin_lock_bh(&pm->lock); + pm->subflows--; + spin_unlock_bh(&pm->lock); + return; + } + + update_subflows =3D (subflow->request_join || subflow->mp_join); if (!READ_ONCE(pm->work_pending) && !update_subflows) return; =20 diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index 09b4b359d960..465928c59917 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -310,6 +310,7 @@ int mptcp_nl_cmd_sf_create(struct sk_buff *skb, struct = genl_info *info) =20 spin_lock_bh(&msk->pm.lock); msk->pm.local_addr_used++; + msk->pm.subflows++; spin_unlock_bh(&msk->pm.lock); =20 lock_sock(sk); --=20 2.35.3 From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on2072.outbound.protection.outlook.com [40.107.15.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 393622565 for ; Tue, 14 Mar 2023 07:31:30 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hQjz+sRuxOGd04Xtb1gKP/KKimJiH9XLPG9VW/0y47nrHfJzA9ay96JXYAdPNZZu5rEMQesM2VntgCs0h80wan44EXDujo21cdSISuU6sVHmHpjAKnKmjVFNORBxoRNRDo9NVzY5R4L+ek/CRF8gJvrLAVRuPmMTtql0ZegyQKZDEYBLOHYWR1UdlVLSFa3mrtz9GEIWmVnRQI2BnSS5N0l8+qwNg92GOeTKhHbv8cI0udrOz6wapKtjOIM41MwJoH7aG9H7NsWIAqwfI1nqR4QqElbRwiY/r/vevBypIwJpkCoXKEdy7rKjjIRdI2ZKbIAMKG1VkJRfBFCvyiH9lQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=3cEHu9sm6jyJ5EEeZTAYPrwYn5yftBFE7FFnVv0DsyE=; b=I66a071Jy/eeAnZUBtBZUiThJpuTClqcDor2k+jv/zDSmw1nhBpIfwk4hmpKEPBU+DHGs/jREofzqG7Y2wFQ3hxZ5wpBLAHtZa9gfncK7pE9CvPl9+d1gLjtATpTMY6brz1XreFa9OrTZvLJngNngdWK5E7Nb0QVi8jszO5WAo3qk/8CJNCciVoCHWRknspLlIqbfoFsweWpDYdyH4NWvZxyxwh5aYYAjX4rGkaJjCIduI2gRj8ry7MN+Qpv3USOOIHwgWnu8vyBuABAze8T5ylHbwKpSfvO6vWGRFtEoF0aUOHFqNygDKGmAN50JLD9Gfrd2nAu5EAiIIJOnj8EFw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3cEHu9sm6jyJ5EEeZTAYPrwYn5yftBFE7FFnVv0DsyE=; b=ZQYm/WR0fF383jzjFuSx90uGio5eEM1G6fxZJdP6pI8PE1NVH6fbekE4rFT8xjA/HB0BeRlVqOAkCxxSsHO/W3sZ6OEYsbimI/GzlQzxcbv4n5/tb5RQz81R0vnKSxGErAkdXfV5NZIDXP56/KYDIAVVWp3tjdzKZmtWcad4MKVD6X2nKhhvnAXsptWEcnpH4ffOlp+tQLHfRyGVwP06wx95FA7MPDfV4e7UySskyqPlHkWfVdBVv7k6UPiUFZR0g1x1NELohDqzPkxeVsEHvHF28BI3QW7OXzj+Ct7GQtRuLG9bdhTm+IXXl1ei/xbjn8g1642pyZ1cYgeNwSpOSg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:31:27 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:31:27 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 6/7] mptcp: make userspace_pm_append_new_local_addr static Date: Tue, 14 Mar 2023 15:31:43 +0800 Message-Id: X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TYCP286CA0134.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:2b6::16) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: 7fba9ac3-4017-498f-9824-08db245e1f4f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: T1LVi+UD9x0glk++ei8uqhzGewN+O2k4gMjP7oOGsJy4AL/VFPPV0xz/HAisG/qipobGPQlFc3+sfd+QhGyomQJnbbmE+Z61Q422gARlsIbbDv7Bp7LNk8LJad58IxMWumx7UJ/E37dsbcD+wAO56wUVgzmhKpZ1mWWqyEHtP7DxVzBkhXWxJz7jgiY93V9vsvdlWbtwWYVNjNdOKw15M6lUCCmDymdWaOHPFdfIdlFJEVU5kWSle/8VYGdPwK0l9dJLrBrPMfsnn4k1Eo81TAyBqwX6Co58Fav/xo9Oc6NMr8SBpd6CDzgIVAvy778SWHi4IT3uZXdVZKdQFztn6Ul5rwrX5gr71BO5xv34xER5FiNVBTxozGhsGrrdZqJ3ozPGKyhAZ6XiU+Nkzw4+pR2ugp/iUdC/1qdkwbfaIXg8I2v5VKyqi06dodxqoh7JKaLsW0dLQC3qFPlyfqccGSncpiDGNg7bDpAq6czmDSzkIxlSb3oXLdzr4F7iCMfI/dthfmWZwUwQXi06fUwf9VNmr1bztjzv9hkmbx3Vi2XomqsmYwsyXPhk4ae4H4wlwAI/C+3MvXABzgN2B6c4JKPBs0vCVgx7YL5w/P7pHyT09Z8K8iR/1P5yzsG0DYgi75DbFCw/SffsPAsJ/q98l+tJVUyT/dLr5AG+BQGRD1tWcgM87FJXUfSA6Ctt2Cyo X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(6506007)(6512007)(86362001)(6666004)(107886003)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(83380400001)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?rzNC2hfcQiSUhtllXurbwqTubP8G7gr2FBO+hTpVyeUYOiJdRVuHHgyXcHG2?= =?us-ascii?Q?JlvsRbjgeqa1Hl60k/egmXznc4LS3siFDAvGnfkvvmw4gWGiqMMKigutiLYM?= =?us-ascii?Q?6ew+F/WjEnU8CVW+lLjHX7+r65tQeeRSkPCH+jR5pPq8hOSTwFHGms30s3oZ?= =?us-ascii?Q?U4U6dWUGF2MxMcFR33xoCttpakLPcJm5wzZm7u/X6uO3OfAV8c3BMf47GSbj?= =?us-ascii?Q?/FaInnKyUTWAfF8XW04JHxPUQrkDhbmbjP5IiUjOS7++FA7WfP4Gu6HCFI1f?= =?us-ascii?Q?QFxTv8fRoKoAz4/GYs5EETuinodTrXmciw2tsx+I0rrSxScakxllDAhUV3Br?= =?us-ascii?Q?BMSOTWgV4ToOPbEgyzidb0r6ieEqrt2toNRBFDPLgelVScP0VVt0J0I00lHG?= =?us-ascii?Q?pAb3zxtFcmVImpjBZ/a+AGsUabe8gNVFMXVzltBD+QGw5JROuqr7WERblBrU?= =?us-ascii?Q?hyhIPFyD3spvzMm+2SDcjhW2NCxFPsg2uG6LbYeNS4LfTQ/sSsZwgLh6kV9B?= =?us-ascii?Q?2cFopuiMmuZe6/VR5aj9uiXkD9QFBlSBWYtpMU5RgSpqeEA3kMv0m7oqUJIW?= =?us-ascii?Q?IsW+gubu8Y7LhAn2U0OtDf2OQDz0l9jeEXBqRGSgvdpzZkbDaflDxJnLhRV/?= =?us-ascii?Q?2788ogEN+sWb9rgndlWL1z02fslHu+eW7MfIEamOd2nUmIPCSiTGdk3ad8RZ?= =?us-ascii?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pO3KTjhD21lIRCZLBehjeKZv?= =?us-ascii?Q?/A=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7fba9ac3-4017-498f-9824-08db245e1f4f X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:31:27.5455 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: yOA/KtBXlRJ7aLW8HZJ8km9W1o79QndYTF7ivJqvbfDE4ZWdCZgqfz/MkKZ8yN9HTys9RqqoFgRbmghvCBj4tw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" mptcp_userspace_pm_append_new_local_addr is only used in pm_userspace.c, so make it static. Signed-off-by: Geliang Tang --- net/mptcp/pm_userspace.c | 4 ++-- net/mptcp/protocol.h | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index 465928c59917..2bda1a217709 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -25,8 +25,8 @@ void mptcp_free_local_addr_list(struct mptcp_sock *msk) } } =20 -int mptcp_userspace_pm_append_new_local_addr(struct mptcp_sock *msk, - struct mptcp_pm_addr_entry *entry) +static int mptcp_userspace_pm_append_new_local_addr(struct mptcp_sock *msk, + struct mptcp_pm_addr_entry *entry) { DECLARE_BITMAP(id_bitmap, MPTCP_PM_MAX_ADDR_ID + 1); struct mptcp_pm_addr_entry *match =3D NULL; diff --git a/net/mptcp/protocol.h b/net/mptcp/protocol.h index 46962a2581b4..421e587a4d62 100644 --- a/net/mptcp/protocol.h +++ b/net/mptcp/protocol.h @@ -849,8 +849,6 @@ int mptcp_pm_remove_subflow(struct mptcp_sock *msk, con= st struct mptcp_rm_list * void mptcp_pm_remove_addrs_and_subflows(struct mptcp_sock *msk, struct list_head *rm_list); =20 -int mptcp_userspace_pm_append_new_local_addr(struct mptcp_sock *msk, - struct mptcp_pm_addr_entry *entry); void mptcp_free_local_addr_list(struct mptcp_sock *msk); int mptcp_nl_cmd_announce(struct sk_buff *skb, struct genl_info *info); int mptcp_nl_cmd_remove(struct sk_buff *skb, struct genl_info *info); --=20 2.35.3 From nobody Tue Dec 10 08:34:43 2024 Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on2081.outbound.protection.outlook.com [40.107.14.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 69F882565 for ; Tue, 14 Mar 2023 07:31:40 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Tlze/a/C9PXt0O9dc6Gsoy5hQNtEdwlpV9j1uee9u0RAhZCS0TRsb8XsQYWdmb+KS4J2+HkV3isSxu7bCa9/TasdncDag80puXpRaYLuc0g62z0oiYkuwFAAF2Y03TQ1qi7KC/KWYJlkpP3MjlqnY4qaHR/FeSs+KIwpoZMR4nlS4xR+zvHI65x/G6+FyqR4DWh3C1cyUr8M1yGvqRY8hbRJzPSNUsxynHMP7IDwJJF06MOFZb9FEQNbAxy8UaP5I7vLYf9yd9kmFH9FbGUJx1+/UkpyLPMRalHwQbVfTu9n+krQQO8H1xEh7TkRUUkLuXdU8FrBFcTJGA378Y91SQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=sg06QCUNxOtjdN1eNGzTpNV3CUoqRJIORsSCRteWPtU=; b=ipAuCuG5RFe+BOWMxcai8Xs8Vwi5StV2p1eZSAPESgt72Yh70lcwWNvutbjAUzCIRPoaGcZIzpE4UbU/3+8QsuifWqAXgMdEN17MGcPwK3JnEVbBPjR5k4Q3xRABnVJKLDR9IUpDASckLNFf6EElf6b47rBUZfXetOOF9ax8pb7IGFvbfR2gCxcPAaR9Xpt/7QZk6M9kbaWttGe0LKfl9EqS3F9xHmH2r5AUVoxV5nb700JeRM2GULdyStU8q+9xnUV+Xty35SCr/QoQlVXxUU+s6VaUPt234/NY8IXeDXYqLf8R/jRJ0Yyia/eeBQ2gx2ueCAT0X9MVmo9N0e0/dQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=sg06QCUNxOtjdN1eNGzTpNV3CUoqRJIORsSCRteWPtU=; b=JZg3e65bbwtCPL7O0Xft3ldieRmwE4MqE7fppgiUvfDanWFBXaPw9+yzFdA6h2StOIUJ50J7TRJz50hq7E7Vxn+8/t64DW85l0PT5suA7hGPeg+HN2WZ4hiuKEDcyqTz20Siol+S8IF+ihrRbfI69tBR2eqYeNIFbILsj9P9mVwH/zZBFh6nM9Yx+IJVhJvp+6mQMMZk2i+/x3tTLqh2tS1eTrjhn9io2ec6QBFXVzqJzSFhmkiO2ZreLmIGQ6HaRFtObIdIobhVx+p4PQ3ooEH8ONI0IAuv0nXIZPkzIcBI0UTL0del41qtaUbT6/uAsMb8PjHPCG4tcj07zwOn+w== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) by DU2PR04MB8759.eurprd04.prod.outlook.com (2603:10a6:10:2e2::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.26; Tue, 14 Mar 2023 07:31:37 +0000 Received: from HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e]) by HE1PR0402MB3497.eurprd04.prod.outlook.com ([fe80::f6b0:27af:a96f:ab6e%4]) with mapi id 15.20.6178.026; Tue, 14 Mar 2023 07:31:37 +0000 From: Geliang Tang To: mptcp@lists.linux.dev Cc: Geliang Tang Subject: [PATCH mptcp-next v5 7/7] selftests: mptcp: check userspace mptcp_info Date: Tue, 14 Mar 2023 15:31:44 +0800 Message-Id: <9511e6740c7249bcdb48ba8716b9248e073b99a3.1678778977.git.geliang.tang@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: References: Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: TY2PR06CA0041.apcprd06.prod.outlook.com (2603:1096:404:2e::29) To HE1PR0402MB3497.eurprd04.prod.outlook.com (2603:10a6:7:83::14) Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: HE1PR0402MB3497:EE_|DU2PR04MB8759:EE_ X-MS-Office365-Filtering-Correlation-Id: ecd6a8c0-f6ad-4eeb-7ed3-08db245e256b X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: m/UTfpanglGNeP5EX0cVpYG213NzHHgfVz80rLSoQBuaY+Dz/IqjXwf/C03j8BySyndOyyYh1txCidCHslikRHbyByvAoYPK0+y6WolsIoeeOwQ17P8ZjoHmcMICsI7ffwjPLzAIRy1D0JFMZA/IR0HPcaHUUCLIUg2WkwoJ+8UhxYUO7RABZ9sjUFiZzRCXxvTsatLAXdYRwKExE+IgPivvQ6HfysPfoIe82xyh04J5PCpAcdTNW8zDh8/R4W8ExN28UO1tAmdHaDgTgxocDKWdukuyoy1jCW8dqeT5lh9vhd/VVcq8JnfcSai05xsnyy8iWRGos3Tqg3t7SPAk95w33whnKmPzXOPaa1crxQ1Q7sgsP4R3p7MnX9CkBp9wqsCrsGOE53ozzk/NvfkrxBDbnsK86nWkN5NPYTqnXNClaEULQl7kFJmB54ENOyATkzl3WfyXJDNwffVOTJpJ1E/GfWMGiwyeFqxJLrspOxrTOmOmaWlyGPqfFFsRZxF1h+iIs0OwM22cJpMPWDICQBTmGbvOmPzEYew1bwLK7cpvEv88+MUILv/Jg12vnUK9evWHOUXKPDY/xqyLaK59NvRwW8+H304BFRB50EqlPqe/XcGOmeuVaZ489SKH3cOYuQcSyTS3ROqK3QmJLSle5D1qiovvmNROVbpwp2lppV+vPQ4H05+dp9mm4zSLu9wr X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0402MB3497.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(39860400002)(366004)(376002)(346002)(136003)(396003)(451199018)(36756003)(186003)(8936002)(2616005)(41300700001)(478600001)(26005)(5660300002)(38100700002)(6506007)(6512007)(86362001)(6666004)(107886003)(4326008)(6916009)(8676002)(66476007)(66556008)(66946007)(44832011)(2906002)(6486002)(316002)(13296009);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?xrfMGnFhtfN+6NwQUvyfLeuT27cK4Wt4x63BJsNSgsFq8KEVTfhrUh4V/+Bz?= =?us-ascii?Q?r2ta1AjCuh2fqrjRZYfpgxg4hsuy6r3qEeAhNlSbFPhcdb378e9CKmOyUCWT?= =?us-ascii?Q?7Ri+yK+T/L+hFOD1cMjJrePXVc1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z+eiMQkEfZXZDoB5Z4NOUMGJ5q/M2oZgR7Qb/jKoiRFNrXpxK5lGj?= =?us-ascii?Q?v4HgyR2rICYEE5/HC58Yp0s28VmJpJ0YaQ4kpY7+w9xfxR/TM9yesl72Gq3/?= =?us-ascii?Q?gEgTRrwLEWCn6/u0/I8lIgqpOXfZkE2qWd11Tu9Xh+ctjifHrULbkreSpwHb?= =?us-ascii?Q?EKXunZnzrsRdXgKeIAyiAfSjAOmJnSaquIMKPDKnZNhYjNzlIFkpc/RXaJMN?= =?us-ascii?Q?ra2ARRoGmoYAeRTWiqdgCY98eFo1CG5sq4RSoTFsxXYbmLvvSRjflcFHkFYR?= =?us-ascii?Q?GXIPeJB+u2EjEy/SRGMwrQT8ti0vUto+WwefsC5M8INqvCEJzRTHen96vASh?= =?us-ascii?Q?sSmnsG1NeCMfzVx1sbBvHzCkwb2J/ySR6fpG4s/SopZfq9u2x2iWNDKD9ReA?= =?us-ascii?Q?w9vV4fRKv/NQPVqdLSUb9eI/XsDR3kQvZ3O9DLcSUXtjgjyPNW8BWMS7i7kE?= =?us-ascii?Q?L38b9DtX5lyLO2xB89qCTKvIdAlydU9b1iaeu5hGVn6V33Q//SR2uwHpJr0c?= =?us-ascii?Q?edJiNzMcFyAEZoZKXhaOY6cNoXj3LrlpimhbaWA7ywe2mcD1hf+pIHoizj2M?= =?us-ascii?Q?6w=3D=3D?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: ecd6a8c0-f6ad-4eeb-7ed3-08db245e256b X-MS-Exchange-CrossTenant-AuthSource: HE1PR0402MB3497.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Mar 2023 07:31:37.8103 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: i30XAQCXFDtIV+Nwig21klPfbPdRd0O4TVbdCvHqLia4YC5b11DkUZ+SngWKGQJ9uYK0OxlQg1PTWSFFx/ovVg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB8759 Content-Type: text/plain; charset="utf-8" This patch invokes chk_mptcp_info() to check mptcp_info of userspace PM. Signed-off-by: Geliang Tang --- tools/testing/selftests/net/mptcp/mptcp_join.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testin= g/selftests/net/mptcp/mptcp_join.sh index 506120401abe..8ca5accd5c82 100755 --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh @@ -842,8 +842,11 @@ do_transfer() tk=3D$(grep "type:1," "$evts_ns1" | sed -n 's/.*\(token:\)\([[:digit:]]*\).*$/\2/p;q') ip netns exec ${listener_ns} ./pm_nl_ctl ann $addr token $tk id $id + chk_mptcp_info subflows_1 sleep 1 ip netns exec ${listener_ns} ./pm_nl_ctl rem token $tk id $id + sleep 1 + chk_mptcp_info subflows_0 fi =20 counter=3D$((counter + 1)) @@ -906,11 +909,14 @@ do_transfer() dp=3D$(sed -n 's/.*\(dport:\)\([[:digit:]]*\).*$/\2/p;q' "$evts_ns2") ip netns exec ${connector_ns} ./pm_nl_ctl csf lip $addr lid $id \ rip $da rport $dp token $tk + chk_mptcp_info subflows_1 sleep 1 sp=3D$(grep "type:10" "$evts_ns2" | sed -n 's/.*\(sport:\)\([[:digit:]]*\).*$/\2/p;q') ip netns exec ${connector_ns} ./pm_nl_ctl dsf lip $addr lport $sp \ rip $da rport $dp token $tk + sleep 1 + chk_mptcp_info subflows_0 fi counter=3D$((counter + 1)) add_nr_ns2=3D$((add_nr_ns2 - 1)) @@ -3148,6 +3154,10 @@ endpoint_tests() pm_nl_add_endpoint $ns2 10.0.2.2 flags signal pm_nl_check_endpoint 0 "modif is allowed" \ $ns2 10.0.2.2 id 1 flags signal + + chk_mptcp_info subflows_1 + pm_nl_del_endpoint $ns2 1 10.0.2.2 + chk_mptcp_info subflows_0 kill_tests_wait fi =20 --=20 2.35.3