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 46CD0A0352; Tue, 25 Jan 2022 02:09:22 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D2D6942721; Tue, 25 Jan 2022 02:09:21 +0100 (CET) Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2085.outbound.protection.outlook.com [40.107.243.85]) by mails.dpdk.org (Postfix) with ESMTP id 3DC2F41186 for ; Tue, 25 Jan 2022 02:09:20 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IDiUyGZDRISbsPMed04ntsK+Fo+zxYSGgtutlS5h6Fq98bELm3hoxw2WcyRT3Ip/hasv9xnA3ad2TLA/Bq8eMZ0GSPRte40kyhaLkCM4oZbVeeygHLqAUf+6WqY5qcma/j82IeSCVIM/D0u6Fk+T6jBS4Ft8lS41GbrtW1exICIzD542wgwnGEPzxxA6AKzjOqnBNfDSRCWsqLDPR80Z1Vflx60A2oVGftqp0sWOqcRc9JcsW+grxuF4XB6PObaLS6yJATNYetV6JW9RkOZokIDzIHjj9lnaQBRpZE3RpsfhPKzzHVJpF+JXovC8h8+99znV7di2BIFbfaHdo2Y9nQ== 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=No84VoJ7OIzNUN8/P4kB27KCn+M5FappWEZ/XmpF0SU=; b=GOo+1plbp52z0eorgP93+6g009T5ehUeDSbhG7O8G/X8dLuQFHvyy5wnKXfHrHdeLSUjautwDU4LyR5yp5zNTDXW2YVw8pJ9B17Uv2I0+Ed0ABhM+59fag+JAWmEc3AoD+iOO/2v/NqCU+3PwOolqw+kGPWhlcDNOdYWWJ55UIxaLFhgEXYh0OVkebUaceUTT9GzznL7xEwWutlvh8ftSxgmML+LYEnOHFMYcijAMD1ng2dgCFoNgkzu0l9h5/xpwAQJ6xJjRbt+V+3+RB+onH816rbEZ/Z/v9/FwnXjrKVFzThMRBx6JZgAW8+Rpb8PT1gIjHX+IwZwokCCtb1IDA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; 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=No84VoJ7OIzNUN8/P4kB27KCn+M5FappWEZ/XmpF0SU=; b=XOAIYPhBo5a+VUIEwIc/xmce7fhygx0o/2a2nFE+pjBN0+5u4C4S5/zPziNo3Odg7cjyZvkMNOsGnlE3H9Ckh7iw4IROAOkv5qiK9JXzx+tktZe/wIS2aorMbMUdiMcS0cY91JpV0/4liN86+0nFGmUAI8kNQL4gRHA6ngQnzjVmXFQuTqleJND+WKvM0PdeMNN9R0I6NosE1iLxKcmjbkjymPUcBSWFYx+A/WYHxwCY9ppzOhNfdMVJC9OuIydmCCrJi7bZC48Bh5gcShzmMG5rF2rVyLQH5S9e/zxK/9u8w9muGtKFOAqavZm8CQGR+XkOI7QLyQj4tC8YyQsjSQ== Received: from BL1PR12MB5361.namprd12.prod.outlook.com (2603:10b6:208:31f::6) by DM5PR1201MB0043.namprd12.prod.outlook.com (2603:10b6:4:57::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4909.13; Tue, 25 Jan 2022 01:09:17 +0000 Received: from DM5PR12MB2405.namprd12.prod.outlook.com (2603:10b6:4:b2::20) by BL1PR12MB5361.namprd12.prod.outlook.com (2603:10b6:208:31f::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4909.7; Tue, 25 Jan 2022 01:09:13 +0000 Received: from DM5PR12MB2405.namprd12.prod.outlook.com ([fe80::cd5b:cd8d:cd38:8c31]) by DM5PR12MB2405.namprd12.prod.outlook.com ([fe80::cd5b:cd8d:cd38:8c31%6]) with mapi id 15.20.4909.017; Tue, 25 Jan 2022 01:09:13 +0000 From: Alexander Kozyrev To: Ivan Malov , "dev@dpdk.org" CC: dpdk-dev , Ori Kam , "NBU-Contact-Thomas Monjalon (EXTERNAL)" , Ivan Malov , Andrew Rybchenko , Ferruh Yigit , "mohammad.abdul.awal@intel.com" , Qi Zhang , Jerin Jacob , Ajit Khaparde Subject: RE: [PATCH v2 01/10] ethdev: introduce flow pre-configuration hints Thread-Topic: [PATCH v2 01/10] ethdev: introduce flow pre-configuration hints Thread-Index: AQHYDTV4aP6w3wKbPEeqR9ltmpyzMKxy8wcg Date: Tue, 25 Jan 2022 01:09:12 +0000 Message-ID: References: <3d9945a0-bca4-559-88a1-864d90a11b44@oktetlabs.ru> In-Reply-To: <3d9945a0-bca4-559-88a1-864d90a11b44@oktetlabs.ru> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nvidia.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: ef8b8ebf-24e0-40bd-388e-08d9df9f4cc0 x-ms-traffictypediagnostic: BL1PR12MB5361:EE_|DM5PR1201MB0043:EE_ x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr,ExtAddr x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: MLNmiKImD825pGB00+aKQhugcoieTluuS2KyKd4oaVd2o8NKAuL0q22VfBci/u/X8z7EWe8QCDcMnMZF5wZVqgAgWfnznVMetCD0L83f8nLLDoyAGMYPE7sGR1z6BnoLbbd0JUERV+X/VXAkZZ/ynCY9QfjsEbvLGtR3bJ9WDKp1T786GN/WwJiOxW3YDkeU1qupuCrWwWbZNOWQU8M7C+/5zYNEdi8jBL8OvzdvnpVMx84l9o26uIu9fUH7bPxK0lnXsMxQnGg/Ijson3tzNgzDSqf6PZwJ7IDcHc3VxS3xrQUA7Qu+50KWHnHmHtyzqFSO8v+P5ZZVlnWtoQrrXLaSVZx3qk0XTDmPTOSqpzXZIFL8AJkb5iTT0KybeO4mC9f/g3QQKNkP9JAxO0/Zkl7MwstmOGi9ulaYzTh5gdl6lSpB3ACCAVLA6wbQ9qeFnen4JWgW9WSCCArKX9IZCCLKE0B3NB/EPoy4ls/iNNQiDx3V1kTdNPwiJxj7PvKr7/DZSH8/BI15Z9lCUfI/jBQSJdcMAMQjPejWpTZs/yERBDXAwNRBkV0o+81OmR6SsjcFzxdCQfqlbKEiIERy1YN1G2+3d+RxkCZRyUfIFJiISviJ41N0sPu7WTcLTAjTuejogGTHHHqaJlJrZXqLj78V7an2xUSU3Of2RlwqQ7yk9+8Htr4/ugZ4ditR1UFsocbhGAJ++qdsC4Nm993lCg== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BL1PR12MB5361.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(186003)(71200400001)(9686003)(55016003)(508600001)(64756008)(66476007)(66556008)(66946007)(7696005)(2906002)(122000001)(8676002)(4326008)(83380400001)(33656002)(76116006)(38070700005)(86362001)(66446008)(38100700002)(52536014)(110136005)(54906003)(53546011)(6506007)(5660300002)(8936002)(316002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?QGtttAmPG64O5fldc38+NICCKI2Q6fF7Dy0bSnj0Z4ipGp4WkrfcN/LzATKc?= =?us-ascii?Q?hHOdEb7WtxzWA4RfYih5Af6v8TaFQqPTFB/UmxRuwVZD5bLDLHogNYbeOxIX?= =?us-ascii?Q?DxdabMomXBY5IlU3B4AAdmINGq39400kderrYjxSU9vPci0AiyE0lg9mO+I0?= =?us-ascii?Q?a9rJS9D7f0uHmXYsXVLNjdoTvUd6boASviz/zOSFAIRcFdtVZR9LvtxodQ5q?= =?us-ascii?Q?XEK+fSTJjNpU/TdGu0XeqIyfOJ/XPAAJMyNndjMxQaBm+I4dVbApcvorySUD?= =?us-ascii?Q?7z7TI6sYm97K9K8grW+4PXCj1j8XgxPwIkwkveHwvaUj6UITsYbBHFUUfC90?= =?us-ascii?Q?efTICPadOja4oEsfFO4PfpxbbhHJnaOPwYtGCqE093XZc3exhxiGKw9jeFvj?= =?us-ascii?Q?L7GYvQdByE6IgsBGSMLJeAFz0yrBQliqhfjhcU7+yvuj1u9NQhNExytZ88Dx?= =?us-ascii?Q?XSIyiYM+858GLVoLRpR5z600xLvDZDKaD6myKgIFUrEpRcx3iwqt6RvGamNi?= =?us-ascii?Q?vdYSWluuST73/tcIaNJDk6hVlnEWbixwR/f+vKN3iL2xz4nEl+gCegvNggWa?= =?us-ascii?Q?6cs30cefVJK30TNSqWedsn+BlE0BmXeFoelK2WSFj8apuM1qioSmTi7vK87t?= =?us-ascii?Q?WD4ZmdEFliJb/u32kjsg9bvtwgX8EaUQBZ12NU8QySeJjy3bX9mA3StgpIXy?= =?us-ascii?Q?QB9uHGI5m1FqYMexig4RhMb55JCpTP4S6CkLCNUd4Y61UcjlhWQpEhKQrfkF?= =?us-ascii?Q?0Wk2PAhUFutuL6TtDR9Hv/gr02XgjP07wzbfzeOxb/4UQTzmmIT6RqmNTwRL?= =?us-ascii?Q?rV2lt1fLOF64JfiQP/oYuFHOnaGb8oj8V0OXb0RBqJDGMTPM3jfWW6MJ9KyJ?= =?us-ascii?Q?3GHpnENPJcWvzmQLVXWUDewTRKQjRPRnLi8LA+ndbOt8Dd42r4YUftQjSMfh?= =?us-ascii?Q?35CRrzc+e1P5jKn/NXox6ujBPimmZQijeY7weRUCfUJYfSxsc68zfv/5CI7p?= =?us-ascii?Q?Jcs/kROwXXUUYY9nAUbMHuv0P/1ABf+tQin0ak6rtrOVmc2FjGVVy93WIR7t?= =?us-ascii?Q?HmzmwYz5KdKnqTLW5FLovLOTjNzrxVjfVNMuZVJSDsWh8Dvv2ylKuV2QKo1Q?= =?us-ascii?Q?8O7GrmugiDeZ/836Gfid0yD6os+c1JNIrLBFQ/Uj1qKtZXreNySsI9Hmx1WA?= =?us-ascii?Q?l1hjTtmIYskU/LClbNbL5kx+qTlTRztSa4zRs/6FkErfaQkAYv+hwAvxLn5Q?= =?us-ascii?Q?r9YMnXwi+wYC5NiarULmvZiaXSxCtaRdruNtBZSDuqi3XrRucSioWorigIOh?= =?us-ascii?Q?J28Bz1dY3/HqEck0xI4QmEa0kbnt9xfz2TAHp0wmap0vR+y9yu8MlQ0AAimg?= =?us-ascii?Q?9r4Kusswb//1oghgKNqedpBcC0Turd0i+csDcdG+YhNHxURWc2GaiMtUP2bS?= =?us-ascii?Q?jFxQ18jGfbtiYYZ9mQTrH/MCywTZpTZFosbD60DJ1af+bdGnaMBV6BeBjmKN?= =?us-ascii?Q?gH/A3GTsgZGC7VseDknkQ8Bint8P0Qi6t1pkecAlSHTzhDnWPxv83h+twoHR?= =?us-ascii?Q?TTygvShAgc+v145AxCO5+A0AhM9wiqsve3y116d3ybwH4tL2r93ZtIroyeHr?= =?us-ascii?Q?6UTWxI/SVFx93QisDH7cdv8fvA9xHApJlPf5YDsLuxPdFFw7racAiXe2+Jzx?= =?us-ascii?Q?MK/ABwQe/ncwL8jTFYwy+agsMP0=3D?= 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: DM5PR12MB2405.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: ef8b8ebf-24e0-40bd-388e-08d9df9f4cc0 X-MS-Exchange-CrossTenant-originalarrivaltime: 25 Jan 2022 01:09:12.9314 (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: zpgtXe9UPw1nT6jVVJ48PMDwgK5kYHCKYdOgEc1m44wkwkMsf9n/5bzbxX06TqvVHv5pRSKf+Og+dRFXsfywiw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR1201MB0043 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 Sorry, Ivan, missed your email last week since I wasn't in To list. Adding = all the people back. On Wednesday, January 19, 2022 8:07 Ivan Malov wr= ote: > > +Rules management configuration > > +------------------------------ > > + > > +Configure flow rules management. >=20 > It is either "management OF ruleS" or "rule management". > Perhaps fix similar occurrences across the series. Yes, thank for catching this, "rule management", of course. > > + /** > > + * Number of counter actions pre-configured. > > + * If set to 0, PMD will allocate counters dynamically. > > + * @see RTE_FLOW_ACTION_TYPE_COUNT > > + */ > > + uint32_t nb_counters; > > + /** > > + * Number of aging actions pre-configured. > > + * If set to 0, PMD will allocate aging dynamically. > > + * @see RTE_FLOW_ACTION_TYPE_AGE > > + */ > > + uint32_t nb_aging; > > + /** > > + * Number of traffic metering actions pre-configured. > > + * If set to 0, PMD will allocate meters dynamically. > > + * @see RTE_FLOW_ACTION_TYPE_METER > > + */ > > + uint32_t nb_meters; >=20 > If duplication of the same description is undesirable, > consider adding a common description for these fields: >=20 > /** > * Resource preallocation settings. Use zero to > * request that allocations be done on demand. > */ While this is true today and all these resources behave the same way if 0 i= s specified, there is no guarantee the same behavior will preserve for any additional fi= eld in the future. That is why I prefer to keep the descriptions separate for every single mem= ber here. > Instead of "nb_aging", perhaps consider something like "nb_age_timers". It is not technically correct, aging may be implemented as a timer or a cou= nter. nb_aging_flows maybe? > > + * Configure flow rules module. > > + * To pre-allocate resources as per the flow port attributes > > + * this configuration function must be called before any flow rule is > created. > > + * Must be called only after Ethernet device is configured, but may be > called > > + * before or after the device is started as long as there are no flow = rules. > > + * No other rte_flow function should be called while this function is > invoked. > > + * This function can be called again to change the configuration. > > + * Some PMDs may not support re-configuration at all, > > + * or may only allow increasing the number of resources allocated. >=20 > Consider: >=20 > * Pre-configure the port's flow API engine. > * > * This API can only be invoked before the application > * starts using the rest of the flow library functions. > * > * The API can be invoked multiple times to change the > * settings. The port, however, may reject the changes. Let me sink that in, the shorter description the better, I think.