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 DAA6A43AC4; Fri, 9 Feb 2024 13:12:07 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5DE8442E64; Fri, 9 Feb 2024 13:12:07 +0100 (CET) Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2049.outbound.protection.outlook.com [40.107.243.49]) by mails.dpdk.org (Postfix) with ESMTP id BC52540697 for ; Fri, 9 Feb 2024 13:12:05 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cBw4FYVupvRaXPtdpZGQP/qcHvIpEt12NK0PdmaR7Nc32JQwFIcjpp0IuuuoyhEhojOp7ennSNmeZl+Rg82GHR1kl1WT77/JjSRyJ0lC4onT1tRcgUf4NHU+cQt7sFSMnstuk3bFRF2Jxj1EBR8vw90OOEIkfpCFUKG3mBEjMTFk2aiu2W/GR8afvFqqztvjfb4/ng7d++MS7XtdCzHOhcBPS9T8sVNSqCGLbt9Gii1H6EqyrSdQpqXM5lwp7TZYWkrewjUw5wkrWPO0HzjI2tuDh09QkUS1DgNxG/vUrXcsOupn9BmUgeE7c4WfTHZNFc9LgZ0NL1HwjrXvUT3SyQ== 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=9bTFGTNL9hT4OsKLEsVnfL8SK1NvsRFNrqdtoNrW8+8=; b=BvY78FmzcHpHsTHnYBUTl2HDiImYA+/SOGSxCsJr9MWfaI/yOTVjbFcL0MLBP6KWIb6LsOGMYqpPzoTXKzLL5QKBnLWYsCfvJrvf9MvTmOkReRJykUUaH8tR4UqsoNdn5/YqRs0kWGsN6etQXBq2tqAY9RYwElCUzfWvgTIliWjHOGTFB4BwRX31wJZ00l6tkrA6NvXqzaZBf9x4yZPbsWVNxPEP/dDJYHtK3N9PqqlLIeYvPzRLLMCziWr7uUQ3p6cCNPAXU4kHNCCTnrbzC27QaFHtEVZhIl69XRWKvNjJFNQ9QC4+vEGmbz77AykrIzruEzCpViT04Pr6Si5vXg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=9bTFGTNL9hT4OsKLEsVnfL8SK1NvsRFNrqdtoNrW8+8=; b=rGd53GwI136GY+ifjQyK6UekSjdqOxYKGb+KuLgZZ17ZYLKZUGVX37okRy0RlPuFWHxq6RpJP5UsgDidFXennRbiGe203XynBewIxrGysHW8BiMo5z71ZcAesOGfavbqR0nw+XLYMxG+/gSp7NF8inYPSYMjSk7VwEbpAaPvygY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) by DS0PR12MB8478.namprd12.prod.outlook.com (2603:10b6:8:15a::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7292.12; Fri, 9 Feb 2024 12:12:01 +0000 Received: from CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::815a:45e6:cf5e:479f]) by CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::815a:45e6:cf5e:479f%4]) with mapi id 15.20.7292.009; Fri, 9 Feb 2024 12:12:01 +0000 Message-ID: <59a69287-cde3-4e9e-8174-c454f964fe5e@amd.com> Date: Fri, 9 Feb 2024 12:11:57 +0000 User-Agent: Mozilla Thunderbird Subject: Re: [RFC V1 1/1] net: extend VXLAN header to support more extensions Content-Language: en-US To: Thomas Monjalon , Gavin Li , orika@nvidia.com, andrew.rybchenko@oktetlabs.ru Cc: dev@dpdk.org, jiaweiw@nvidia.com References: <20240130112520.1971315-1-gavinl@nvidia.com> <20240130112520.1971315-2-gavinl@nvidia.com> <76ab3ffb-5f6b-4f16-a3a8-4e80f5afffcb@amd.com> <2384008.yKrmzQ4Hd0@thomas> From: Ferruh Yigit Autocrypt: addr=ferruh.yigit@amd.com; keydata= xsFNBGJDD3EBEAC/M7Tk/DfQSmP1K96vyzdhfSBzlCaGtcxNXorq4fALruqVsD3oi0yfyEz9 4YN8x7py0o9EL8ZdpOX0skc0AMCDAaw033uWhCn0GLMeGRKUbfOAPvL6ecSDvGD7CJIO9j0J eZUvasBgPdM/435PEr9DmC6Ggzdzt8IuG4PoLi5jpFSfcqxZFCCxLUDEo/w0nuguk2FTuYJg B2zEZ4JTBZrw7hIHiFh8D8hr6YA6a5uTofq1tr+l048lbtdFUl8TR0aIExVzE4Z8qKZlcE+9 RQaewjK5Al1jLE4sHdmd3GN+IvgDF3D/fLsi25SKJDeGSdeHkOmaX0qGeM4WKIfU6iARRCiQ N3AmBIxZ/A7UXBKLaOyZ+/i3sE6Wb53nrO4i8+0K2Qwyh6LjTeiJAIjYKN43ppxz3DaI+QwQ vI+uyHr4Gg0Da9EPPz/YyKauSeOZCfCB5gIfICO0j6x0SCl8uQ2nLpjxcZkf0gjcwUzP3h+S 3x6NfDji9YEij0zczW/dcSpGgZ6vsFpPrtnP9ZXy6J53yp0kJtOJoOlkEFFdU2yCZnCDseum CoudmGLZVvS0/DzHDJejq+3kK3FDGktZBOxZIIpal+nFqS7lVgOZc4+huVv3jyhzoAUOEyXA XK5j6o7g8STUY+z33QNnHpdLvecMwuzmvqy0jR54yAbZ64mB9QARAQABzSNGZXJydWggWWln aXQgPGZlcnJ1aC55aWdpdE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XF1GlofpGbe1lj4KUJVse5g3qwV7i9VrseA8c4VIZewdIjkzAhmmbxl+8rM/LKBH dZUMTzME5PFCXJIZ83qkZQ795MTe2YScp9dIV7fsS5tpDwIs7BZNVM1l3NAdK+DLHqNxKuyO 8Zk= In-Reply-To: <2384008.yKrmzQ4Hd0@thomas> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-ClientProxiedBy: LO4P123CA0193.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:1a4::18) To CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH2PR12MB4294:EE_|DS0PR12MB8478:EE_ X-MS-Office365-Filtering-Correlation-Id: 9f0b5871-901e-4f20-3957-08dc29685234 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: GtOC1Q+Z3llYSOPJqiFLAvNy4vlhUjHmN73pk3q2Glm2ZRf1DWj2Ai7RVssyUbRBEv0vXa/x5S4iUeGlIk9PxpAKo2GphIvITt7NuFk4tpoqXXiVhfPYccSdrz+Y58FeCr1IIp1zpJkNlMWn+k63g4DgqusCaIluosvX5HhLf1EXNe5zMm4qss96brsLy0rKd5DXCmnlQI3TiTNDwCzYpg7IJn6vst3AVJUhChlz51ai7M/Rw1CPY4I01ayJfgT0aB3NTFcoKE92ImC+ixoc+7qxrGgiVJaa72RhZc6un8LBIhPiObVuV86NF/yodxvJrciQ9LvkACSYUDk52HR8uu3nhGzCnG9nazhR252oOEcKdPHhq2VaXZb+TaUGXBrIvaH5w/6QCztTCGK3l7pi2EnXROZvev2yBgGZuhacm6Rny3Pgd4iUxMg3gaPdIUnUBlP/HkahiFEqlQJ5HA2cIqoAmYoL5rZhq0LuN99CxctVDZjxd07JDXVfsgetO2EW3+ORO57AIrR1IV4nieK8t1iUYk1U2YVYYceWIePhM0KFHpI/mUSTU5i1767o16xz X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH2PR12MB4294.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(376002)(366004)(136003)(396003)(346002)(39860400002)(230922051799003)(451199024)(1800799012)(186009)(64100799003)(44832011)(38100700002)(5660300002)(2906002)(31696002)(86362001)(26005)(6512007)(53546011)(6506007)(6666004)(83380400001)(2616005)(110136005)(316002)(66946007)(8676002)(8936002)(66476007)(66556008)(4326008)(6486002)(478600001)(36756003)(31686004)(41300700001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?WjJ3UFl2MHh1anFDR2UwTlVNekc5UTE3L2RUQUl5ZDlrY0tZMmNGVDU5Z1pR?= =?utf-8?B?UDBvR3RHZUJpcVIvN2JhOWtIVHlTdDN1QnNLSUFDaWJMeXgzQmlka2QrTGt6?= =?utf-8?B?TGRTNjlVdVhqKzZxbUtaRmt0WlllME0vZDQwcXp3VmdSRzNqUVhxRDBoWGUr?= =?utf-8?B?cWlESTQxajFqTno4eEQybGE1TUJzNmgvRC9SNFJWbVZRTkdJSE9YODVRVXA4?= =?utf-8?B?eUVzM29rUXFiTzBpbnU2bHVFcTN4a3JVV2JGVisxeWVnS2h5SDkrbkFkRzQ5?= =?utf-8?B?dFlXZUorYWVaVlEreCtBcHU0MEx4M0Z0b1BLckxHaklod1VmZmk0VGMwNXht?= =?utf-8?B?aHF4Y2hodEVUV0Q5ZDdyaVd2QzBTWTNhZVBKb3RlL2ZEVlhNYVJGLy9ZYlRu?= =?utf-8?B?QjgzWHZCbUlxc3I0bWVjQlNFYWZRQXBOdUZxci9ydDd5VDF1cGRqR09iWDVs?= =?utf-8?B?S3ZkL2dDTW52RWRiOTg5cHdzaG8zTmdVVjFYa1l1azg4bW9VVFFMWjk3TDRC?= =?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ZBL21TZyttbmlT?= =?utf-8?B?cmVwM2tqTUgzb3Y0UDBFZ2dqSVpidEtsMHczZVpjTWFpRnFIb3VERmIvTmVK?= =?utf-8?B?SXQ2Y0RSSU93c0I4aFFacU1LaHdtVkZtdXUzYXBwbnZjMUdYU09uMm14dkk1?= =?utf-8?B?dHpIUE1iajJCMnMrcGExcGd6R3BTWlZscEJVbFQwTDdPV01rZStQRlM4Sm9v?= =?utf-8?B?ZTlpdEZnSWZ4TE45M2tMSWUxRFRWWVVxL3B6TzVmc0VrQ09NNnZwQTRzOHFl?= =?utf-8?B?dVdYV2QvNTcxNjFZRUozdVcrVlJKUkZSVUZJT1Fnc1A3Wm9BVFQ4eDFvbmVO?= =?utf-8?B?RHY5bEhXTnI3clRTRjc0L2JoVUFMZFhkbk9udTRuUzdtOVhOWHRBNVlaa1lP?= =?utf-8?B?RVdaaEcxaWFOUEF0U0RIc2xqc1dwb2gwcGJaNkt4dFEwZGs0a1U4VENNU3Zh?= =?utf-8?B?U3NXcmFJUkN6V2FndW1zd2crNWd0cHRydmc2M2ZraGViZVVHeG1LRENmM3Fj?= =?utf-8?B?KzZvbEh2RkFra3JpSjB3dUYybFFva1ZaMGlHT3J6TGQvTm5jYWI2dHA3VE1m?= =?utf-8?B?L2dSaXF4V1hBcyt1YUcySUtJTlo0Z0ZML0RWWGJSZUZaQk1KK29DbHpaK0Vx?= =?utf-8?B?WFNrU1FuQTBHSVhON1JTMDVxOWFuNGFMRElqRjhNL3hBUTJQS1FBUDdsakNa?= =?utf-8?Q?qRY4QtXWa3vzNOt/jQl+oGry/?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9f0b5871-901e-4f20-3957-08dc29685234 X-MS-Exchange-CrossTenant-AuthSource: CH2PR12MB4294.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Feb 2024 12:12:01.5021 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: sPVe/QQwhafVcPuduG1l44dAPECv/wd+tLALoWIQ/2hLx/YZ2ZUSXs67WJG0iFKC X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR12MB8478 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On 2/9/2024 10:12 AM, Thomas Monjalon wrote: > 09/02/2024 00:54, Ferruh Yigit: >> On 1/30/2024 11:25 AM, Gavin Li wrote: >>> Currently, DPDK supports VXLAN and VXLAN-GPE with similar header >>> structures and we are working on adding support for VXLAN-GBP which is >>> another extension to VXLAN. More extension of VXLAN may be added in the >>> future. >>> >>> VXLAN and VXLAN-GBP use the same UDP port(4789) while VXLAN-GPE uses a >>> different one, 4790. The three protocols have the same header length and >>> overall similar header structure as below. >>> 0 1 2 3 >>> 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> |R|R|R|R|I|R|R|R| Reserved | >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> | VXLAN Network Identifier (VNI) | Reserved | >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> >>> Figure 1: VXLAN Header >>> >>> 0 1 2 3 >>> 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> |R|R|Ver|I|P|B|O| Reserved |Next Protocol | >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> | VXLAN Network Identifier (VNI) | Reserved | >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> >>> Figure 2: VXLAN-GPE Header >>> >>> 0 1 2 3 >>> 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> |G|R|R|R|I|R|R|R|R|D|R|R|A|R|R|R| Group Policy ID | >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> | VXLAN Network Identifier (VNI) | Reserved | >>> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >>> >>> Figure 3: VXLAN-GBP Extension >>> >>> Both VXLAN-GPE and VXLAN-GBP extended VXLAN by redefining its reserved >>> bits, which means the packets can be processed with same pattern and most >>> of the code can be reused. Instead of adding more new items by >>> copying/pasting code for the VXLAN extensions in the future, it’s better >>> to use existing VXLAN infrastructure and add support code in it. >>> >> >> Hi Gavin, >> >> The motivation is to prevent code duplication, and the code mentioned is >> the driver code, right? > > The motivation is mainly to provide a unified and more explicit API. > >From user perspective, I think existing approach is more explicit, because it sets VXLAN or VXLAN_GPE flow types. I am trying to understand the benefit, how unifying flow type in the API helps to the user? >> Overall OK to unify "struct rte_vxlan_hdr" although it makes the struct >> a little complex, perhaps we can consider extraction some nested structs >> as named struct, no strong opinion. >> >> >> But not sure about removing the flow item types for VXLAN-GPE, or not >> adding for VXLAN-GBP. >> >> Think about a case user adding a rule, which has a item type as VXLAN >> and in the protocol header some bits are set, lets say first word, last >> byte is set, how driver will know if to take it as GPE "next protocol" >> or "group policy id". > > The driver may decide depending on the UDP port and some distinguishing flags. > If you want to match on GBP, you should includes the GBP flag in your pattern, > no need to use a separate item. > Why not be more explicit? It helps to driver to know more about the pattern to be able to create proper flow rule, if there is an obvious way for driver to differentiate these protocol extensions, and flow item type is redundant, I can understand the proposal, but otherwise I think better to keep flow items for extensions. When a rule is set in HW, HW may not care about the protocol, as long as bits in the rule match with the packet, HW can apply the action. But for driver to be able to set the rule properly, it needs more explicit information. Lets assume driver API get a pattern with 'RTE_FLOW_ITEM_TYPE_VXLAN' type and "struct rte_flow_item_vxlan", at this point driver doesn't know if it is VXLAN or any of the extensions. Should driver go and check GBP flags to deduce if it is GBP flag, and what if they are all zero, how can driver can tell if this is GBP flag that is zero or is it VXLAN header and bit is reserved. Or I will just make up a sample, it may not be accurate but please take it as a case to prove a point. Lets assume driver API again get "struct rte_flow_item_vxlan" whose first word's last bit is set, which union in the struct will driver check to detect this, GPE one or GBP one? This can be GPE-"next protocol" or GBP-"Group policy id", if driver knows this it can set the mask better for the field in the rule. Driver may try to deduce this extension information from other information, but why not proper specific flow type for each extension instead? >> And if a specific HW detects VXLAN-GPE and VXLAN-GBP protocols as two >> separate protocols, won't only having capability to describe VXLAN >> protocol in SW be a limitation. > > I think the driver may know based on the flow rule. > > That's a good question about the item granularity. > What is the separation between a different protocol and protocol options? > How flow item should match protocol variations? > My current thinking is that we should minimize the number of items. > >> If the target is to remove code duplication in the driver, can it be >> accomplished by extracting code that parse the common fields of these >> protocols? > > Driver code is not a concern as far as any driver can implement the API. > Got it, I want to clarify this one. Where the code duplication via copy/paste that commit log mention occurs? > >>> In this patch, all the VXLAN extension header will be merged with VXLAN as >>> union if the overlapped field has different format among protocols. The >>> existing VXLAN-GPE will be marked as deprecated and new extensions of >>> VXLAN should be added to VXLAN instead of a new RTE item. >>> >>> Signed-off-by: Gavin Li >>> --- >>> doc/guides/rel_notes/deprecation.rst | 5 +++ >>> lib/ethdev/rte_flow.h | 13 +++++- >>> lib/net/rte_vxlan.h | 67 ++++++++++++++++++++++++++-- >>> 3 files changed, 80 insertions(+), 5 deletions(-) >>> >>> diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst >>> index 81b93515cb..f9cf931b77 100644 >>> --- a/doc/guides/rel_notes/deprecation.rst >>> +++ b/doc/guides/rel_notes/deprecation.rst >>> @@ -95,6 +95,11 @@ Deprecation Notices >>> - ``rte_flow_item_pppoe`` >>> - ``rte_flow_item_pppoe_proto_id`` >>> >>> +* ethdev: The flow item ``RTE_FLOW_ITEM_TYPE_VXLAN_GPE`` is replaced with ``RTE_FLOW_ITEM_TYPE_VXLAN``. >>> + The item ``RTE_FLOW_ITEM_TYPE_VXLAN_GPE``, the struct ``rte_flow_item_vxlan_gpe``, its mask ``rte_flow_item_vxlan_gpe_mask``, >>> + and the header struct ``rte_vxlan_gpe_hdr`` with the macro ``RTE_ETHER_VXLAN_GPE_HLEN`` >>> + will be removed in DPDK 25.11. >>> + >>> >> >> We have 24.11 in between. > > Isn't it too soon? > Should we remove at all? >