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 E1741A0579; Thu, 8 Apr 2021 04:31:45 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6622F40698; Thu, 8 Apr 2021 04:31:45 +0200 (CEST) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2044.outbound.protection.outlook.com [40.107.93.44]) by mails.dpdk.org (Postfix) with ESMTP id 983FC40138 for ; Thu, 8 Apr 2021 04:31:44 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=h3a88sOlcceYgjU7qJF3TuQm7l+j+3p7N/2R8wExF1u1DzdQF4jdQ0vTvww5glBQofvMx0JAh0TA0oLwQS3LAX9Ps6sAasopb2Yiv9mzt9oFFGEFMXuBYTNn7DxZgWPEd/Lg8WUI5TbyLwtkVtNWup+etxxsA5+bb17HUOA1ji6i8b7ZWBrSvBKqc/mgO9bfwBzzr7z5ShyUkPl0mNbJ0l0KUNkARoU9hrgoLCjkS+OTpl2VO40iG4AiR3f+JT8qWDOA9+3ESJo2a36l4bdkxBd7LDFSEbFOS33MDWCJjS4gej1BXiZTLM6RIA4NZZJDJYLQCMVHBXq83voGSGseGg== 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=/0QZhOesZuqLXULFbTtmYYJ/H0RQdfZzAcs9X0fiqX8=; b=oCd47KYJCNYQQbMJhL7sjmXkcKAv3NOC7ifuGN1ZZcnm64Qus+d741dT8VSu/JD22YHjqZSQ90br53sjA4RHVeglVzNYIkcY8IxCOMqjhp+VUWwNiSVx02wYVCna0IuYT/E02Rz8bib0oRxnwtonlU3wlrO5aOqac39TnmfGfm67RD5L3szkoWsemRrKwu9jmkIzFYThkirt+bNjtQJmmXqBv0+hW3IHbzhLtHq6SacuJChWNcToWN1ulRv7BfadzIFZ7Z7ftNJUP5gCcmB9fCCBwaDXwI7+AN0cQo5Q95GQRvsTPX6o4atoVGK1MmEhhRznu8u/jHyv7ohjftngfQ== 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 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=/0QZhOesZuqLXULFbTtmYYJ/H0RQdfZzAcs9X0fiqX8=; b=XF/dAz5MDnVAxPtIwB7P7tlknQWmYe+ucTNwrVJxvJ9t0pjVaHV/vhK+Gk+4WZwSy5ZMSRWkOz+/8kGVeydN4o3tB+c3rnKAjGOlwaLuY7UJUcq65rcUBaaNcC68XUK8up3dPHvnQy3fc+4FndLRGlvRYMKHmUSCDl1IStt2nlLkpEUKU/ddirwoBklIz2vy9gkI6pn0188QLVjOrxqb7Yf9NXOGKo6RMmnFeVV1YXXGfhm6Qsme5Gh8qWGR95MT3QL+R1ePnXEjdRQ0cOYwS5bLyeVS/jeXov2huhXM/iA7FzVUiDfqbxEVCXZADWSBd1N5JOkVsX/Hf9Yw/0kyKA== Received: from DM6PR12MB4090.namprd12.prod.outlook.com (2603:10b6:5:217::11) by DM5PR12MB1577.namprd12.prod.outlook.com (2603:10b6:4:f::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4020.18; Thu, 8 Apr 2021 02:31:42 +0000 Received: from DM6PR12MB4090.namprd12.prod.outlook.com ([fe80::fd19:da7e:347b:87da]) by DM6PR12MB4090.namprd12.prod.outlook.com ([fe80::fd19:da7e:347b:87da%4]) with mapi id 15.20.3999.034; Thu, 8 Apr 2021 02:31:42 +0000 From: Li Zhang To: "Dumitrescu, Cristian" , "dekelp@nvidia.com" , Ori Kam , Slava Ovsiienko , Matan Azrad , Shahaf Shuler , "lironh@marvell.com" , "Singh, Jasvinder" CC: "dev@dpdk.org" , NBU-Contact-Thomas Monjalon , Raslan Darawsheh , Roni Bar Yanai Thread-Topic: [PATCH 1/2] net/softnic: check meter packet mode Thread-Index: AQHXK+p3Kx/PSeS6WUOUDujO7QYGqaqp5pug Date: Thu, 8 Apr 2021 02:31:42 +0000 Message-ID: References: <20210401061618.1478961-1-lizh@nvidia.com> <20210401061618.1478961-2-lizh@nvidia.com> In-Reply-To: Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=nvidia.com; x-originating-ip: [139.227.253.12] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 4cc2804a-6a55-4d75-bc96-08d8fa367262 x-ms-traffictypediagnostic: DM5PR12MB1577: 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:2512; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: YuzcVXEYjr+IJWsL4mGQ6eYVXfWYs6vYg0eWbaN/rS46kMguYUuVM5jNslH6IER4g+M3XYo8x3EAJW7FsZ5HuhMB7M/L3yjU0mfWX2nFbQoXb9u3MBAipHYL2TYdSxOcegPsVz3tklARonAkHR8xuWdp9VVUC6kgbth0NvlxdBPu2udciMglevbkrwFGGYz+yv5ntvPSq9Om8ckQk/5A29xdn4fQ7sqr86q6feWREXd7uSNJTgOkIUwmfCQpajLfE6qziAkY0C1OuBASR0zTcwIe7nJ2VccyDODB59ArbelqxJXrG6yYnGj92PshWQqJrbFS6OUOri0AWpxoCcCyLIyAdhe7OxsORcq9Zt2+eAvkJozVsrD9cHp/dVFjen2R+uqlLPKs8gIcQPWcpvQKIyGkwIsFFs76Rb3UI0QJE83R2ZQbFlmBO0XSYoR4efCcjCxFXBGKO1MspEQcqpEyokWJxEM6cm8zXwWfhKh1MJrlSkMeQKU5UwOq0bAp0MW9CbIwaLJWhQ5mxQQA5wUYnjF6t+QirM/P6C4UJ/WnloI9F4OcMiTRucoTYwF0GnKGGJ83UUrZuDFV8TNZYHQc8rNeTSHO841Eq8OKF8O027Dfe/RkEm21nzVkgudy8/RfeEW+8HeH2PEpYA99tNOUDZjX1K522UDVtevWayfdjqpYV37A4FR1mKb4ctJQuVSP x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR12MB4090.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(346002)(376002)(136003)(39860400002)(366004)(396003)(478600001)(8936002)(7696005)(71200400001)(6506007)(53546011)(8676002)(9686003)(52536014)(38100700001)(110136005)(54906003)(316002)(55016002)(921005)(107886003)(83380400001)(4326008)(26005)(2906002)(76116006)(5660300002)(86362001)(64756008)(66946007)(66556008)(33656002)(66446008)(186003)(66476007); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?G1TNa3do561lJrPv/fZPjZoVBjCOV9Hi02yC2R7BHr0RP0jPAOgKcgxLCpbT?= =?us-ascii?Q?oET9PdE2nvd36cyYMgceWMkiCea/yejvyTEZrDxKisogSqfyxF3h7D7fF40A?= =?us-ascii?Q?HdbArvHhxe2L0298C+fSYSMn1CRhs/DVTRsVgxMUhw9YEK1CVom+2wRmU0q9?= =?us-ascii?Q?0NZIr/iNn+gga1n+8/0NcGQ9w6gARaaZIo6PEUbx9JnwdBqplbkP1fsX/CaO?= =?us-ascii?Q?/NdiXFQBjP1/WTRF1RIJjN/uzy876RFBBs3nh7y3ieGaw3qd/NHAK8QTC1Ln?= =?us-ascii?Q?Zkzd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Fc?= =?us-ascii?Q?CvN7twy9/JPqVq9zWQBoAp7oHwsAzhqXFc5gYXzz1q4YrcjIuZ6+7WLs/qyr?= =?us-ascii?Q?Mxf9xLq9fKBEY2UC//w/3XZckr67tjP/sz9QSlXz1pZiJcRxARWYTEorFOhH?= =?us-ascii?Q?X6qfPkVtN/xdy5UOixGEamgu?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR12MB4090.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4cc2804a-6a55-4d75-bc96-08d8fa367262 X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Apr 2021 02:31:42.5215 (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: 4tZblH5AnnV57reThFX5KS6x/4GrR8B1BMpYElD2iTnUnsMy1L/YliLV5TNP5e78 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1577 Subject: Re: [dpdk-dev] [PATCH 1/2] net/softnic: check meter packet mode 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" Hi Cristian, > -----Original Message----- > From: Dumitrescu, Cristian > Sent: Thursday, April 8, 2021 4:13 AM > To: Li Zhang ; dekelp@nvidia.com; Ori Kam > ; Slava Ovsiienko ; Matan > Azrad ; Shahaf Shuler ; > lironh@marvell.com; Singh, Jasvinder > Cc: dev@dpdk.org; NBU-Contact-Thomas Monjalon ; > Raslan Darawsheh ; Roni Bar Yanai > > Subject: RE: [PATCH 1/2] net/softnic: check meter packet mode >=20 > External email: Use caution opening links or attachments >=20 >=20 > > -----Original Message----- > > From: Li Zhang > > Sent: Thursday, April 1, 2021 7:16 AM > > To: dekelp@nvidia.com; orika@nvidia.com; viacheslavo@nvidia.com; > > matan@nvidia.com; shahafs@nvidia.com; Dumitrescu, Cristian > > ; lironh@marvell.com; Singh, Jasvinder > > > > Cc: dev@dpdk.org; thomas@monjalon.net; rasland@nvidia.com; > > roniba@nvidia.com > > Subject: [PATCH 1/2] net/softnic: check meter packet mode > > > > Currently meter algorithms only supports bytes per second(BPS). > > Check packet_mode set to TRUE are rejected. > > > > Signed-off-by: Li Zhang > > --- > > drivers/net/softnic/rte_eth_softnic_meter.c | 8 ++++++++ > > 1 file changed, 8 insertions(+) > > > > diff --git a/drivers/net/softnic/rte_eth_softnic_meter.c > > b/drivers/net/softnic/rte_eth_softnic_meter.c > > index 0cbf94e8b0..50db74f52f 100644 > > --- a/drivers/net/softnic/rte_eth_softnic_meter.c > > +++ b/drivers/net/softnic/rte_eth_softnic_meter.c > > @@ -128,6 +128,14 @@ meter_profile_check(struct rte_eth_dev *dev, > > NULL, > > "Metering alg not supported"); > > > > + /* Not support packet mode, just support byte mode. */ > > + if (profile->packet_mode) > > + return -rte_mtr_error_set(error, > > + EINVAL, > > + RTE_MTR_ERROR_TYPE_METER_PROFILE, >=20 > Can you please add a new error type for this specific error case, i.e. > RTE_MTR_ERROR_TYPE_METER_PROFILE_PACKET_MODE. >=20 Thanks, I will add it in V2 patch. > > + NULL, > > + "Meter packet mode not supported"); > > + > > return 0; > > } > > > > -- > > 2.27.0