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 6566542D46 for ; Sun, 25 Jun 2023 08:38:38 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6019140ED8; Sun, 25 Jun 2023 08:38:38 +0200 (CEST) Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2084.outbound.protection.outlook.com [40.107.223.84]) by mails.dpdk.org (Postfix) with ESMTP id 1341340A7F for ; Sun, 25 Jun 2023 08:38:37 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lzVpfpMHy5mBbeDNgO7L8DH+rNntjjxO6vyPKPNw68WXjv8K4PaUPOWuG+wuZ7CNexnWX6LthiXDqoQFOXIV3IPeOntaRSJpjrK+ia9s1365gmz4N7Wo+0NBe1wo//tEwhKuaBZoRUHsK/Rf0210BDFFJ2J5fws+BBm4cE/4UVsRrmj2IYHJhMZm7IKoWrtgrGh1Rs3Ez3MT4WmVV/VzjivyxPwGsMpaNyKaMxcIRhLD39cny8d/j/2sy/VMk6Jmqqy2Gp/0+sn3ST9O8PY96twcHT8bBJMiG7JBx4SZbTNbDl2N3rjax2m1DjHntduScYfi2eFkss+7cRvQjHdK0g== 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=TaovcZMJ7o0lIDK/MIQk5uztf1+z9HtXnCfF9duAn9Y=; b=JPUCTXxY43q9fnDDJdGbOBE2M8TiqGlgHEWyHTEJ9JBlJoxKCoUIhTYPrPxZUuYvW5f+BGBgK5pPwCQEcCU1hK2RGgNbUpPyH9Na892aCnHkHa0FfzY78F1mwNro06T92rJx0XXNazDvCCZeRzdWVrC16fockMo5TgB0s5FJfzWaxowyCn7CwdPoUqc0uGRTf2/60doKyHcxw21Lp9d0BzLomVgQk/gNZp4AmKDaEEYkM1PeTk4tCCmT89kx3dHNR1SMjSnCavuQdPX6Kk3YV2e7C+1Sfj++1aeG0WVmWQSwYazx/X36dOI3Asjs1/V1cB2fcZL2C8YVrn1+i6FSog== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=linux.vnet.ibm.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=TaovcZMJ7o0lIDK/MIQk5uztf1+z9HtXnCfF9duAn9Y=; b=alFuM9DIPoaStwoYQWRUvRiZ7RpMb4hS/zj775JohFCx2cnP5SkT6zZHO4NupskfN3ygbknmHpWm8JVOcrKibIBtA7JvC9rBIzPXYRD/35OVUvpZeVind3bJSjR00LV6ERjOpmD3pc+b8OIQAtMlWLNqhwPr94iK/u6Fds4E6k0ohtd32nXht2fFRV5fCoGu5F+rOFaERJOAqgSqIqA+MutdqVUuMeG7YMyBHS4nwQQzKcN5IqhEMlO7ffYKw92XRSay0FtxOhLpr/b2Lwx6t5Fz07rJDQ3i1XJDWrEPvqtf0SxfEld7wo4OdG3Z9AIz6jKK1ltkG3K5LYnk8rhV/g== Received: from DM6PR06CA0029.namprd06.prod.outlook.com (2603:10b6:5:120::42) by PH8PR12MB6988.namprd12.prod.outlook.com (2603:10b6:510:1bf::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6521.23; Sun, 25 Jun 2023 06:38:34 +0000 Received: from DM6NAM11FT003.eop-nam11.prod.protection.outlook.com (2603:10b6:5:120:cafe::ed) by DM6PR06CA0029.outlook.office365.com (2603:10b6:5:120::42) 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:38:34 +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 DM6NAM11FT003.mail.protection.outlook.com (10.13.173.162) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6500.42 via Frontend Transport; Sun, 25 Jun 2023 06:38:34 +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:38:22 -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:38:20 -0700 From: Xueming Li To: David Christensen CC: Stephen Hemminger , Ferruh Yigit , dpdk stable Subject: patch 'net/tap: set locally administered bit for fixed MAC address' has been queued to stable release 22.11.3 Date: Sun, 25 Jun 2023 14:34:06 +0800 Message-ID: <20230625063544.11183-29-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: DM6NAM11FT003:EE_|PH8PR12MB6988:EE_ X-MS-Office365-Filtering-Correlation-Id: aa71f9a9-b49a-4781-8f8a-08db7546ccbd X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: p2zEyOiwhsv5lazXBx8L7pXbFUDccDUwSHVKo36mXklGc5iskZLi/tAznK+IS3MAm92yZ1UWwx3KBrWXE2RVpiZVxfffHwNzmvSRd6MnTbJ96RpqYh5v/ESTGA2fl6nkyU7hQ26x81yuMNDF7uvL5KeKzxyozMB5wkWTKw84hf5qCHsGt40HXCgGE43eUBzzT7Vq7tsycYkmT7eQ57Qoo8QZak6uCTsTP/ixYVE/doya0KM8t+uxjRSM0CNDp/UzgBa4XoxQX1afC527VmjFL3shP7MS3b2FI3/sxv6pV5RBpLyR/+BG9Us0sTMGAvKoEDUIX1kFENPTKqebjzUN/XCZMV/04iquYaX2pprp6c+Xp0Pqw8vnbB43VFMmPA7b41IqY5vKX457kL/mWdC8pXYqf3Oj4TIMtlrfGY6gVozaL1SAvnJMWGZbOZ9gMp4w/H9BZlP0rHfAW3J2xtOjvED2zJ4P6lL70gWvrqGuDeCz2HwtxnAl8M0rQpQ+IPwqSdussAiAUzPVD43Wc92tliRsNR+VeHyy+Q5gI7hSVidNY/1UlFGnBlJxgrWvaiqXoBkyxxrGH3bFMPDhjsF5IkeuMvA9yAiSzlIEMPyJ+hrnfRv+lescjuNoD6ugSSFG8ibeS+cKGgWyCHfkBvduQMrjEH51VXlqDMbf2g8LxyJlqfFuZNDDPs6FKDZojVA7oMcxKMIQh7vi1v3OyQSueocCo+zPxOGru+qjcPDqcViTfL5Cu3pnrZ8zXgUJ/Bt2ZzFB5xLA0eXRYEKpvgAnHQ== 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)(396003)(346002)(376002)(136003)(451199021)(46966006)(36840700001)(40470700004)(966005)(7696005)(6666004)(478600001)(54906003)(53546011)(16526019)(6286002)(186003)(26005)(1076003)(2906002)(82310400005)(6916009)(4326008)(316002)(70586007)(70206006)(8936002)(8676002)(41300700001)(5660300002)(7636003)(356005)(36756003)(40460700003)(82740400003)(86362001)(55016003)(36860700001)(83380400001)(47076005)(2616005)(426003)(336012)(40480700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Jun 2023 06:38:34.4786 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: aa71f9a9-b49a-4781-8f8a-08db7546ccbd 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: DM6NAM11FT003.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH8PR12MB6988 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=8e27036b63097e7df03246570676b549944f8f88 Thanks. Xueming Li --- >From 8e27036b63097e7df03246570676b549944f8f88 Mon Sep 17 00:00:00 2001 From: David Christensen Date: Tue, 25 Apr 2023 16:58:06 -0400 Subject: [PATCH] net/tap: set locally administered bit for fixed MAC address Cc: Xueming Li [ upstream commit c3006be2acab49c6b77ae9c9ef04b061e5dacbd6 ] When the tap driver is loaded and the user selects the optional "mac=fixed" setting, the tap driver incorrectly uses a globally unique EUI-48 identifier (as documented in RFC 7042) of 00:64:74:61:70:. Since this is a locally generated ID, the Local bit in the MAC address should be set to 1, resulting in the new address 02:64:74:61:70:. Bugzilla ID: 1198 Fixes: f6921783fee6 ("net/tap: add support for fixed MAC addresses") Signed-off-by: David Christensen Acked-by: Stephen Hemminger Acked-by: Ferruh Yigit --- doc/guides/nics/tap.rst | 8 ++++---- drivers/net/tap/rte_eth_tap.c | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/guides/nics/tap.rst b/doc/guides/nics/tap.rst index 2f7417bddd..07df0d35a2 100644 --- a/doc/guides/nics/tap.rst +++ b/doc/guides/nics/tap.rst @@ -34,14 +34,14 @@ Using the option ``mac=fixed`` you can create a fixed known MAC address:: The MAC address will have a fixed value with the last octet incrementing by one for each interface string containing ``mac=fixed``. The MAC address is formatted -as 00:'d':'t':'a':'p':[00-FF]. Convert the characters to hex and you get the -actual MAC address: ``00:64:74:61:70:[00-FF]``. +as 02:'d':'t':'a':'p':[00-FF]. Convert the characters to hex and you get the +actual MAC address: ``02:64:74:61:70:[00-FF]``. - --vdev=net_tap0,mac="00:64:74:61:70:11" + --vdev=net_tap0,mac="02:64:74:61:70:11" The MAC address will have a user value passed as string. The MAC address is in format with delimiter ``:``. The string is byte converted to hex and you get -the actual MAC address: ``00:64:74:61:70:11``. +the actual MAC address: ``02:64:74:61:70:11``. It is possible to specify a remote netdevice to capture packets from by adding ``remote=foo1``, for example:: diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c index f2a6c33a19..66595f8312 100644 --- a/drivers/net/tap/rte_eth_tap.c +++ b/drivers/net/tap/rte_eth_tap.c @@ -2303,8 +2303,8 @@ set_mac_type(const char *key __rte_unused, if (!strncasecmp(ETH_TAP_MAC_FIXED, value, strlen(ETH_TAP_MAC_FIXED))) { static int iface_idx; - /* fixed mac = 00:64:74:61:70: */ - memcpy((char *)user_mac->addr_bytes, "\0dtap", + /* fixed mac = 02:64:74:61:70: */ + memcpy((char *)user_mac->addr_bytes, "\002dtap", RTE_ETHER_ADDR_LEN); user_mac->addr_bytes[RTE_ETHER_ADDR_LEN - 1] = iface_idx++ + '0'; -- 2.25.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-06-25 14:31:59.281642900 +0800 +++ 0028-net-tap-set-locally-administered-bit-for-fixed-MAC-a.patch 2023-06-25 14:31:58.315773900 +0800 @@ -1 +1 @@ -From c3006be2acab49c6b77ae9c9ef04b061e5dacbd6 Mon Sep 17 00:00:00 2001 +From 8e27036b63097e7df03246570676b549944f8f88 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit c3006be2acab49c6b77ae9c9ef04b061e5dacbd6 ] @@ -15 +17,0 @@ -Cc: stable@dpdk.org @@ -49 +51 @@ -index 089ac202fa..bf98f75559 100644 +index f2a6c33a19..66595f8312 100644