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 AA46FA0A04; Fri, 15 Jan 2021 19:04:24 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8BA5F141203; Fri, 15 Jan 2021 19:04:24 +0100 (CET) Received: from nat-hk.nvidia.com (nat-hk.nvidia.com [203.18.50.4]) by mails.dpdk.org (Postfix) with ESMTP id 78B7F1411FD for ; Fri, 15 Jan 2021 19:04:22 +0100 (CET) Received: from HKMAIL103.nvidia.com (Not Verified[10.18.92.100]) by nat-hk.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Sat, 16 Jan 2021 02:04:21 +0800 Received: from HKMAIL103.nvidia.com (10.18.16.12) by HKMAIL103.nvidia.com (10.18.16.12) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Fri, 15 Jan 2021 18:04:16 +0000 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (104.47.56.168) by HKMAIL103.nvidia.com (10.18.16.12) with Microsoft SMTP Server (TLS) id 15.0.1473.3 via Frontend Transport; Fri, 15 Jan 2021 18:04:16 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=an/0enVNXCov92xuyF7QoBg6un1jkOK0HBS2bZeGvE7KsZTL/BQf5i1ulR4Q5DhsROUPeXYPEsLdaOWq6PVyOHIpZJf1jgVCh+B9U8vaOQuNfiZUzKn62Y2XWSJ0ITgsh3ksBmhcAEOii+K5p2UtIzkOtRI6dOdAxS7PPHza+kuL+XGfsU5AOnzBarYj2Hw12xmb6Rmq8XHgOWxtSLByHWGR0tOVyii4b8ecmWk3aSwCaCbuEFeKHa5Dr5X36YWnMe2oUNOZLnAzO9ws5lLu6QgMFILjRvoi0xCRqGb+MffdIvq7C9k9YhEM6ZvogzGCPdZZ3rofC/j1xuV+kUetbA== 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-SenderADCheck; bh=i9gT5zvqTxqkwnmwElPhUgZKplq01PGb+M+cphy7TLk=; b=XBoP4s547G/isDy9P7EEvAXfOVJT9kiEOCGRef50gAv5oP4YC/iTIqy/lNuEWMXxFq/5fNOtVRy8EcT0W5f4OLQVheGfgy12yjTH44+gJrUDEv3RbhwCvMn72irraZljx2ekAL/W7484mFmvfOwvApHxLvisQyPCpoTY8mSFX30uHeZdbHu3qEKpogK1HfoIn/B/fmybP2zA0Dx112pk/GfXehqDdk+tJ0n+i2I4aIhIdtJ2yo3WT4FRzk0b3uu6VIVWI27bjFzWBNUlk8zyg9BPyjh2qPe/eSEHdrGrfokZlV6PLcKWLPYm8ekBnUIZmNY/++QEinBPidxEd0GV0g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none Received: from DM6PR12MB4987.namprd12.prod.outlook.com (2603:10b6:5:163::31) by DM5PR12MB1772.namprd12.prod.outlook.com (2603:10b6:3:107::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3742.12; Fri, 15 Jan 2021 18:04:14 +0000 Received: from DM6PR12MB4987.namprd12.prod.outlook.com ([fe80::e1e4:bf73:a753:2665]) by DM6PR12MB4987.namprd12.prod.outlook.com ([fe80::e1e4:bf73:a753:2665%4]) with mapi id 15.20.3763.010; Fri, 15 Jan 2021 18:04:14 +0000 From: Ori Kam To: Alexander Kozyrev , "dev@dpdk.org" CC: Slava Ovsiienko , NBU-Contact-Thomas Monjalon , "ferruh.yigit@intel.com" , "andrew.rybchenko@oktetlabs.ru" , "jerinjacobk@gmail.com" Thread-Topic: [PATCH v5 2/2] app/testpmd: add support for modify field flow action Thread-Index: AQHW61UeeDZXzVqaK0KstQviO0l01aoo+tvw Date: Fri, 15 Jan 2021 18:04:14 +0000 Message-ID: References: <20210113170751.13044-1-akozyrev@nvidia.com> <20210115154246.8770-1-akozyrev@nvidia.com> <20210115154246.8770-3-akozyrev@nvidia.com> In-Reply-To: <20210115154246.8770-3-akozyrev@nvidia.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: nvidia.com; dkim=none (message not signed) header.d=none;nvidia.com; dmarc=none action=none header.from=nvidia.com; x-originating-ip: [147.236.145.126] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: b6cbd6ab-effc-4e36-e3c5-08d8b97ff83a x-ms-traffictypediagnostic: DM5PR12MB1772: x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: LvYq/mXb+oCATPVyh/47DXuEe9LTvkix3y7XP4gtBgRNoccEAWN2J80OO06J2cMKTfCso08/YzuKcwbPk2tM7/2uRDxXHaWCv+HH02qFqXL8tpLCbolwuNqQ1cc3E/BjAUZfLyBsSmhWw17OnBzwYl8czwd8D/z0M4Mtt0Ub109HXjeDxPACIaqgJ2qi4QPoaoZb8kkyIhOoxNTHcexiOGefG5hbP8vQUc2exksUJEhzpKgFpJ5gcgqW/JBSx7ok3Z51b6NVTWXKfMBDFvHZ0a3e1vd7RC3MKHNyoHro3EJEMjlEmTQ8ngAQE4CHByRQGgsatnf387CzM0vxP21w0tLUjdSV1B+syqXZjPUwUua8QNYONBM9v90G8puguRvIwNWr4jY5GV6Odfx7Fki96Q== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR12MB4987.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(39860400002)(376002)(396003)(136003)(346002)(366004)(53546011)(52536014)(55016002)(2906002)(66476007)(9686003)(54906003)(4326008)(5660300002)(6506007)(316002)(7696005)(478600001)(66446008)(26005)(66946007)(76116006)(33656002)(64756008)(83380400001)(71200400001)(186003)(86362001)(110136005)(8676002)(8936002)(66556008); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?3lhF/WZhuPVE0bzdERJIlt+Wb35KRMBF34d89oUXW9G0V3auoWR9N/iYVMp7?= =?us-ascii?Q?VeBKtS77atsITxqBRqN6qrGjR0qLT8zv1behTrox9jvQ6gC9RQYmv/YEMaLy?= =?us-ascii?Q?p1VDuHfmEOkxpPP0mcfguVHoJrzlQKA0vLtNoI7pQSGRfM1XQ0H5hDidXcXG?= =?us-ascii?Q?+9lY036SvdHfH6DaN+fmJNGbneiHNIdMQVEvTTvi8FZ1LLeljSdmOvEcnzKS?= =?us-ascii?Q?OT42vAWWwuAkCQMiWtusmzM5PRJxtpiZ6/sJZX0m/ggMJ3ASTK84jWgdruhU?= =?us-ascii?Q?WpnyJRemNPMmqu60vHGI1DBHryoA3QJzsTxATGsrRwaPXsOTV7HlKwhLRfy4?= =?us-ascii?Q?uU27pimJvGMurye8YqDslQzyjosUojMBgG14Mft8UPHeaLEgJyrUvMEjHiOZ?= =?us-ascii?Q?A9Q+Bq3tnxoHocqvWo3dikHaG4hLbj3k3Q99wwDzxYO+fFi7Gd+3TgUazX80?= =?us-ascii?Q?VgcEsY1ZP6B6yJTtIF9OOKGBVYnCuo81xeecMWVjh7ZxXBjTtVVynhKtSIhU?= =?us-ascii?Q?4bS5Wu/GO/FbeGpJVc0Jz9VecM+NGkU3f5e9oTPOA+cEj/XVtrjXJ/ycT2IK?= =?us-ascii?Q?9SsHNo3FvmFMzxID4UMExQwtSVONNcus3W1paQXxqlmkRcyLzV7eAq9JvLq/?= =?us-ascii?Q?1nMcQzKaoAWb7lOzJyv5RMBk8Ed1gBF0cDoZcn7uRD/HeAIBWFezbjLQUFOY?= =?us-ascii?Q?jAg3cyY4+zFUFvkbBvZrwEeSg+cc9DMvAqg/WF24rerecLNSHAe7pPFbkFAK?= =?us-ascii?Q?/Z2CVFZidUb4U4vlQK2u1EKXNH5do8170QHWYxz8Xv8x7NjfRCjRSt3T2FpB?= =?us-ascii?Q?sNrORAiacXZ2G8Dmj05KtJmCHwb8udjHbgalG02s8pKE+KJPdiT133gMbKS+?= =?us-ascii?Q?xfYxRMUv55vf8YSvyn9JVFvsbbfdaWq0oOFo6CJAqAZh7jYRbnecDf8T0PeT?= =?us-ascii?Q?j51fBz7pBJuH3JRp+mkOJkorz5Ps+dP8h9xm4MnOf5Q=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR12MB4987.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: b6cbd6ab-effc-4e36-e3c5-08d8b97ff83a X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Jan 2021 18:04:14.8250 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: hKLuy6ZjoDjNYeRx/wMVMDz5qOz3eNJBMGe0F8uhvJjCPSFbBp64YhpS/AFP0fkE/kj/anbtRp0hr1CfYfhDlA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1772 X-OriginatorOrg: Nvidia.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1610733861; bh=i9gT5zvqTxqkwnmwElPhUgZKplq01PGb+M+cphy7TLk=; h=ARC-Seal:ARC-Message-Signature:ARC-Authentication-Results:From:To: CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID:References: In-Reply-To:Accept-Language:Content-Language:X-MS-Has-Attach: X-MS-TNEF-Correlator:authentication-results:x-originating-ip: x-ms-publictraffictype:x-ms-office365-filtering-correlation-id: x-ms-traffictypediagnostic:x-ld-processed: x-ms-exchange-transport-forked:x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers:x-ms-exchange-senderadcheck: x-microsoft-antispam:x-microsoft-antispam-message-info: x-forefront-antispam-report:x-ms-exchange-antispam-messagedata: Content-Type:Content-Transfer-Encoding:MIME-Version: X-MS-Exchange-CrossTenant-AuthAs: X-MS-Exchange-CrossTenant-AuthSource: X-MS-Exchange-CrossTenant-Network-Message-Id: X-MS-Exchange-CrossTenant-originalarrivaltime: X-MS-Exchange-CrossTenant-fromentityheader: X-MS-Exchange-CrossTenant-id:X-MS-Exchange-CrossTenant-mailboxtype: X-MS-Exchange-CrossTenant-userprincipalname: X-MS-Exchange-Transport-CrossTenantHeadersStamped:X-OriginatorOrg; b=Dr/XWuQhSKQVqnNcMs5ZuXzPNSIUzc5C6hNqKbhLDm+HPHtpORHoKAnjU/x50B8Rn eqCQOuIDq9k6qmtnCs2BwDwJ9bF7GixAIJrK5Zm1p51Ql1TwSiMoxQAlA3auruerDq P60WHB/avj3WrWtGLduT+7GOWQAFPKzERb4CroXV9a7WVjiUHL2EHykK5qXMVCKqeS k7fQqoJfMm7w+y1DIgPCJBvCRmGo4kqj7gV6Zh63ZCMddwrtUZ/Ls0JB0za8uAMl8u LSTK0Q2pLZtWiyVUZalgTkOrjaJ7hPTwNgCnNiMIJz82qtHgAfSbppJSlIVk6vh4bJ aCmgexIqh5KYw== Subject: Re: [dpdk-dev] [PATCH v5 2/2] app/testpmd: add support for modify field flow action 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 Sender: "dev" > -----Original Message----- > From: Alexander Kozyrev > Sent: Friday, January 15, 2021 5:43 PM > Subject: [PATCH v5 2/2] app/testpmd: add support for modify field flow ac= tion >=20 > Add support for the RTE_FLOW_ACTION_MODIFY_FIELD to the testpmd. > Implement CLI to create the modify_field action and supply all the > needed parameters to modify an arbitrary packet field (as well as > mark, tag or metadata) with data from another field or immediate > value. >=20 > Example of the flow is the following: > flow create 0 egress group 1 pattern eth / ipv4 / udp / end > actions modify_field op mov dst_type tag dst_level 2 dst_offset 8 > src_type gtp_teid src_level 0 src_offset 0 width 16 / end >=20 > This flow copies 16 bits from the second Tag in the Tags array > into the outermost GTP TEID packet header field. 8 bits of the > Tag are skipped as indicated by the dst_offset action parameter. >=20 > op, dst_type, src_type and width are the mandatory parameters to > specify. Levels and offset are 0 by default if they are not > overridden by a user. The operation can be mov, add or sub. >=20 > Signed-off-by: Alexander Kozyrev >=20 > --- > v1: Initial implementation. > v2: Made dst_type, src_type and width only mandatory parameters. > v3: Reworked to accomodate API change from copy_field to modify_field. > --- Acked-by: Ori Kam Thanks, Ori