From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2D26E42D46 for ; Sun, 25 Jun 2023 08:42:28 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2857A40ED8; Sun, 25 Jun 2023 08:42:28 +0200 (CEST) Received: from NAM10-BN7-obe.outbound.protection.outlook.com (mail-bn7nam10on2068.outbound.protection.outlook.com [40.107.92.68]) by mails.dpdk.org (Postfix) with ESMTP id F3C2A40A7F for ; Sun, 25 Jun 2023 08:42:26 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dhIugTjzQwUz0BkGHD01E+z8/Htppf9U1lKyW06RZepRdVa9uJQqL682AMwwgdILAtS3BX1yy+qOcT84IfEkLOt5ZYcmSkB/XNT3wM1tkc/NYXx9DxAoq5f/6eN36Zky/YdWoC/xVTZLFftLn7mgueC42HiMJF+HjhfiLXwmwvmJ/95CNa4JQ4g/M79M3350XDZvrs9TyhbdFKFKtNSvbqBCdlZwPMw0j2mhmdhw17uotXYCk7tqK19h987piZ7DURs6At1XZypd7sPDEj8n/oiu6uIJQenuvgqlgUq9A4wlKvfjLrTIhh8aGh3bDIT7VFGrj7KkMgXIx2W+ei0JUA== 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=p6TkVRE1RJJhb4K7DpvURptAjDuPkzk0UJkJAqSaRj8=; b=ViW1+fTq5CUOkJJc7/cAmJxVjJS9CWcokwR+pk0jMwJ612KyKC2wGxM1qh0kTiADIIo14YmpJpJ3rxCsxwtGvTyO2ov0Ho9BWsoo4jVdYOwipu7EMd2jWmsgXtJfAyOi/F7aXyF9rK9h21gWIRLSmXOttKc2jLPK3FXCqeyBf31hOuxPFE1FVnQusJOxSCye6UipXlH+5GWekg1z35jzudMvEaTgpqBibjwcZfGV2hmi27q+3EuFcdYFu+iQNm5363dLEr0INxFw/u46jG9GqgBOMPzvpmFaRrVKXm1iX/pb7uGEZzjUsGS3D1lVpwkVb9UhJrLS8mPNp4ezE1Kj0g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=marvell.com smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=p6TkVRE1RJJhb4K7DpvURptAjDuPkzk0UJkJAqSaRj8=; b=j/FMHtC+nrihlWSTBRQpC/QNqE0rExcm9SF7ZXkvMEPxps7/N5HZIRJ1TWGyd2QFjuhoyQ2mLYk75axWYbblctC/EQxKFxGw/nxvVo+bAVDJgvGslaBDrkPGdEJn4KRGrZzThZiVPpONyxCDqrCUCEKvLVTPf0FFZZNAiFSQGufMSxZnpGEzsT8qtDXgMeqeYvE07UizEIFp2Z7aHGOZcN5D7tRcBHFICxVlBbVWCqpkbUKKWmWs81eXwtyq7XpS69fp20FwOkdbQuIzTgy1roKrZ8iRy7nLhqqB1Z1WFZ7yMaNtrI5xnPLIY+K4B8uhFGXnrBDYiqU5teRbxZNC5g== Received: from BN9PR03CA0866.namprd03.prod.outlook.com (2603:10b6:408:13d::31) by BL3PR12MB9051.namprd12.prod.outlook.com (2603:10b6:208:3ba::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6521.24; Sun, 25 Jun 2023 06:42:24 +0000 Received: from BN8NAM11FT083.eop-nam11.prod.protection.outlook.com (2603:10b6:408:13d:cafe::62) by BN9PR03CA0866.outlook.office365.com (2603:10b6:408:13d::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6521.32 via Frontend Transport; Sun, 25 Jun 2023 06:42:24 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.161) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.117.161 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.161; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.161) by BN8NAM11FT083.mail.protection.outlook.com (10.13.177.75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6500.47 via Frontend Transport; Sun, 25 Jun 2023 06:42:23 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.67) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.5; Sat, 24 Jun 2023 23:42:11 -0700 Received: from nvidia.com (10.126.230.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.37; Sat, 24 Jun 2023 23:42:10 -0700 From: Xueming Li To: Rahul Bhansali CC: Akhil Goyal , dpdk stable Subject: patch 'examples/ipsec-secgw: fix zero address in ethernet header' has been queued to stable release 22.11.3 Date: Sun, 25 Jun 2023 14:34:52 +0800 Message-ID: <20230625063544.11183-75-xuemingl@nvidia.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230625063544.11183-1-xuemingl@nvidia.com> References: <20230625063544.11183-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.230.35] X-ClientProxiedBy: rnnvmail202.nvidia.com (10.129.68.7) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN8NAM11FT083:EE_|BL3PR12MB9051:EE_ X-MS-Office365-Filtering-Correlation-Id: fda76da2-59dc-4813-3ef8-08db75475545 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: stkgQj/EMFtOCxA22DT9yzo+xIZ/fxRuT2JeGbl4Lm/NXueQKZdZN+5ItbmfAAg6HiQGdhZ3E6H/ggcobDoDxImMscu8a+SFFzMFEmTjFKcoKH/TMJHxJ9EO+VjpruB3KeTYkzxT4CnfKVSMlv2T5SRIwK0pyyPPR2GW/fl48rwSCIej9+57l1Mi/qDEa3yOEnAOIq0AhdIIHyOCTssJBp2Dj5AbxJuBhodKt6KeBDEZGsAFdsgDIJ4QMk2yLDo+N8aJPjac1jbBEPDHvutUeFNxdldtKrsYrr2o7CN9DreIb8pjDznXN1tUBfJUgpysm9oq6lBT2wgVF6zSpcys5VdlqmhFwVpcqUR9m4x7v2QDuUhnZB1pls9SAulhT6VEbUbpkrYbPFo35/xG/oEeYiEJ99Bdxy35k08NWihPK29qAuNr2I2fYfD4MbGW2Z83wkPxlJ+zfHLYn7jwSuBe9YefceQ7KnCnj+ujLG0VaWum/DWi80dsPDBNShjtEDqJ25DKyFRD8vJnJtJUydH+JBrj78kjwGG0Ln7r1KO+BAwhVkR6TVm3vqxIMk1Tzzp+348batTuxUIQ5YwkqKPF+pr/z1Z+30eu3OBbF5kng1YI/KO4t4QgRccjA4rNar/GHfPuTcuaZka8GZobofvqgKf6SojLLj/c3+u5OnzW3mwE5C27i2j2kuEXWIbTEJ4GKjHFwZYlaVWVkKQUXTV8xukr73zg6I8c2m98QNwtNnX9gLZC0Wgp78jNZMklhmlnv+Gmlw6l/TBrhB7AmErCsg== X-Forefront-Antispam-Report: CIP:216.228.117.161; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge2.nvidia.com; CAT:NONE; SFS:(13230028)(4636009)(39860400002)(376002)(346002)(396003)(136003)(451199021)(46966006)(36840700001)(40470700004)(40460700003)(2906002)(7696005)(82310400005)(82740400003)(6666004)(356005)(7636003)(2616005)(83380400001)(47076005)(336012)(426003)(1076003)(26005)(186003)(6286002)(16526019)(53546011)(966005)(36860700001)(55016003)(40480700001)(41300700001)(54906003)(86362001)(478600001)(316002)(36756003)(70586007)(70206006)(4326008)(6916009)(5660300002)(8676002)(8936002); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Jun 2023 06:42:23.4755 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: fda76da2-59dc-4813-3ef8-08db75475545 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.161]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT083.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL3PR12MB9051 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 22.11.3 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 06/27/23. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://git.dpdk.org/dpdk-stable/log/?h=22.11-staging This queued commit can be viewed at: https://git.dpdk.org/dpdk-stable/commit/?h=22.11-staging&id=400a3302ded367ba87527110e5fdee422c9f7af5 Thanks. Xueming Li --- >From 400a3302ded367ba87527110e5fdee422c9f7af5 Mon Sep 17 00:00:00 2001 From: Rahul Bhansali Date: Thu, 30 Mar 2023 15:39:06 +0530 Subject: [PATCH] examples/ipsec-secgw: fix zero address in ethernet header Cc: Xueming Li [ upstream commit fbe585801b90519cd16247dd14ed945d3223dbe3 ] During port init, src address stored in ethaddr_tbl is typecast which violates the strict-aliasing rule and not reflecting the updated source address in processed packets too. Fixes: 6eb3ba0399 ("examples/ipsec-secgw: support poll mode NEON LPM lookup") Signed-off-by: Rahul Bhansali Acked-by: Akhil Goyal --- examples/ipsec-secgw/ipsec-secgw.c | 20 ++++++++++---------- examples/ipsec-secgw/ipsec-secgw.h | 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c index a64a26c992..ea662797a8 100644 --- a/examples/ipsec-secgw/ipsec-secgw.c +++ b/examples/ipsec-secgw/ipsec-secgw.c @@ -99,10 +99,10 @@ uint32_t qp_desc_nb = 2048; #define MTU_TO_FRAMELEN(x) ((x) + RTE_ETHER_HDR_LEN + RTE_ETHER_CRC_LEN) struct ethaddr_info ethaddr_tbl[RTE_MAX_ETHPORTS] = { - { 0, ETHADDR(0x00, 0x16, 0x3e, 0x7e, 0x94, 0x9a) }, - { 0, ETHADDR(0x00, 0x16, 0x3e, 0x22, 0xa1, 0xd9) }, - { 0, ETHADDR(0x00, 0x16, 0x3e, 0x08, 0x69, 0x26) }, - { 0, ETHADDR(0x00, 0x16, 0x3e, 0x49, 0x9e, 0xdd) } + { {{0}}, {{0x00, 0x16, 0x3e, 0x7e, 0x94, 0x9a}} }, + { {{0}}, {{0x00, 0x16, 0x3e, 0x22, 0xa1, 0xd9}} }, + { {{0}}, {{0x00, 0x16, 0x3e, 0x08, 0x69, 0x26}} }, + { {{0}}, {{0x00, 0x16, 0x3e, 0x49, 0x9e, 0xdd}} } }; struct offloads tx_offloads; @@ -1427,9 +1427,8 @@ add_dst_ethaddr(uint16_t port, const struct rte_ether_addr *addr) if (port >= RTE_DIM(ethaddr_tbl)) return -EINVAL; - ethaddr_tbl[port].dst = ETHADDR_TO_UINT64(addr); - rte_ether_addr_copy((struct rte_ether_addr *)ðaddr_tbl[port].dst, - (struct rte_ether_addr *)(val_eth + port)); + rte_ether_addr_copy(addr, ðaddr_tbl[port].dst); + rte_ether_addr_copy(addr, (struct rte_ether_addr *)(val_eth + port)); return 0; } @@ -1907,11 +1906,12 @@ port_init(uint16_t portid, uint64_t req_rx_offloads, uint64_t req_tx_offloads, "Error getting MAC address (port %u): %s\n", portid, rte_strerror(-ret)); - ethaddr_tbl[portid].src = ETHADDR_TO_UINT64(ðaddr); + rte_ether_addr_copy(ðaddr, ðaddr_tbl[portid].src); - rte_ether_addr_copy((struct rte_ether_addr *)ðaddr_tbl[portid].dst, + rte_ether_addr_copy(ðaddr_tbl[portid].dst, (struct rte_ether_addr *)(val_eth + portid)); - rte_ether_addr_copy((struct rte_ether_addr *)ðaddr_tbl[portid].src, + + rte_ether_addr_copy(ðaddr_tbl[portid].src, (struct rte_ether_addr *)(val_eth + portid) + 1); print_ethaddr("Address: ", ðaddr); diff --git a/examples/ipsec-secgw/ipsec-secgw.h b/examples/ipsec-secgw/ipsec-secgw.h index 0e0012d058..53665adf03 100644 --- a/examples/ipsec-secgw/ipsec-secgw.h +++ b/examples/ipsec-secgw/ipsec-secgw.h @@ -84,7 +84,7 @@ struct ipsec_traffic_nb { /* port/source ethernet addr and destination ethernet addr */ struct ethaddr_info { - uint64_t src, dst; + struct rte_ether_addr src, dst; }; struct ipsec_spd_stats { -- 2.25.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-06-25 14:32:00.494455400 +0800 +++ 0074-examples-ipsec-secgw-fix-zero-address-in-ethernet-he.patch 2023-06-25 14:31:58.445773900 +0800 @@ -1 +1 @@ -From fbe585801b90519cd16247dd14ed945d3223dbe3 Mon Sep 17 00:00:00 2001 +From 400a3302ded367ba87527110e5fdee422c9f7af5 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit fbe585801b90519cd16247dd14ed945d3223dbe3 ] @@ -11 +13,0 @@ -Cc: stable@dpdk.org @@ -21 +23 @@ -index d2d9d85b4a..029749e522 100644 +index a64a26c992..ea662797a8 100644