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 515E8A050B; Thu, 7 Apr 2022 13:27:47 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E32174068B; Thu, 7 Apr 2022 13:27:46 +0200 (CEST) Received: from NAM11-BN8-obe.outbound.protection.outlook.com (mail-bn8nam11on2051.outbound.protection.outlook.com [40.107.236.51]) by mails.dpdk.org (Postfix) with ESMTP id AC05340689 for ; Thu, 7 Apr 2022 13:27:45 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LuSyBTEvrql3J4tHSBEp4vYK7JDMl5v26CQEca5+aghWcq/VrHR+BS2ZkSLHjdrDQR8mD+K82ASkUaiueJXd8pAW6qk6lsyh1/tyLbB/BtpEv3eG5mRwvqw3y1CQGPg7LBOzjtx3vrMY9+Pmi5iHlc6l+IMxkh8GMqPpyjG2y8A2KxAvrSf23QmJGH4zD0IhrQIfjmF86Lt5LITfSBHi0iXjTBxgWBMYSjg7Gs6DveTWqS/0WX2XBTluUM7iPsAGblxXqDs5zaQuIBGxwJrvsDV+m8/RR+Ae7Ok4HuVXVW/zFhDt24Sgn0/w1JjRm2SogJ9TS9cTlciVuE8WlyLBqA== 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=JGo+9zvvjnfWOudX2UrcgKZNmJcBrUXoNZSV68Ho/10=; b=cJlrG4Rp8OXp6UDIiM6e25G2IcB5+g4UgIwyMHtg+C1vozF0Wj/H6ri39GRLnh0ybvAF1FUpWgjeDFIdUooNDwH0QTbxXFB5FrG36I0WYBeGITG4RWcL9slvYZ8toOzEJ7qsvvW2dobCHK3CUczMknGWPDOmg7uA68gv2/Cr6FriZAl6xqlleiL86MYi8WuwwHknC2rNBVt62MRiVa8BetUU2c8+a3GUllqJQbd7m5tCorXUgjkW6mB02cF60zvXghUk2OzH9GwB5Ks9eqhQZvj2j60R80WlnjxFztKRtuHHhkcgLWyA0pu5d4njnA3CzZ7p1FAKU7BiXt+4RdtIzA== 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=JGo+9zvvjnfWOudX2UrcgKZNmJcBrUXoNZSV68Ho/10=; b=csKqeBUWjVj+WnIpN9IHj6OVj20ZcHiixEQRYG1RwswGciE4PTqdbxhgRSWlUAWkCfOjWS4eH0jUH/3zFWQ1N9vsY8UiYT2HTzNytVa3e0h6UNsmao2UpsPts73Y3ymIosKCU0ksBaBJisIxcnId5JgN29K3mZ75Cqa5i8DkodwkGHhyxW2Po+YFhuZ80qMuA3T2ncd8coxFf90JvqzQKbluxnPM7dFVH18wxva2kOsQhxbP3UAKtfunp3TIVYeJ4hJOvLIGRbesL5dJOoAxj7hBllLP2KPw8hkaoLjq7Nvzu8t4zBfpTJTywGijrrbA9SxCfct9Tc1GTqkGTBMPmA== Received: from MW2PR12MB4666.namprd12.prod.outlook.com (2603:10b6:302:13::22) by BYAPR12MB4743.namprd12.prod.outlook.com (2603:10b6:a03:a5::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5144.22; Thu, 7 Apr 2022 11:27:35 +0000 Received: from MW2PR12MB4666.namprd12.prod.outlook.com ([fe80::2835:6c79:95d7:a2bd]) by MW2PR12MB4666.namprd12.prod.outlook.com ([fe80::2835:6c79:95d7:a2bd%3]) with mapi id 15.20.5123.031; Thu, 7 Apr 2022 11:27:35 +0000 From: Ori Kam To: Jack Min , "NBU-Contact-Thomas Monjalon (EXTERNAL)" , Ferruh Yigit , Andrew Rybchenko CC: "dev@dpdk.org" Subject: RE: [RFC 1/2] ethdev: port flags for pre-configuration flow hints Thread-Topic: [RFC 1/2] ethdev: port flags for pre-configuration flow hints Thread-Index: AQHYSkC7p6FDYnzBBEWHPbckHZgTyqzkT6jg Date: Thu, 7 Apr 2022 11:27:35 +0000 Message-ID: References: In-Reply-To: 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: ef3e7368-6209-4df5-b2ab-08da18899d68 x-ms-traffictypediagnostic: BYAPR12MB4743:EE_ x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: FYCHaPBGw/3sSMufm9CGew4Griean2o/yt/7YJ24YzW/9QhbsW8685JbDKCCtfOqflGSDyaDYpzO2aBk56oXHknEC5poMuWyYNMudDzFZmr0Hqqkc5p/++hXfDgob85K8KOcyIbFZ0Tx5yvhDvgu0771pvY/1AQ3AfptiN5y2u9kb74nEFLJJ+m3KocohECeRtEdyrPkRCsthJWREP+rC8XlW0kIBj8JlD+W8ladObtJZgi5YRkyoCfnB6A2gRxJi9qdzUOt5ybIOI4YBc7SuiFmRZ2yS8hEuY2Ddb2/XQNP45egldf5KiuArt0oG4TEMvpU9dTiPSFtY49w+XZOtX37X/YpqoEpwc7xINqtEm4iStc1Js5uo7jt+bWX6qAVrJlIKyDAnThVng7hfuexw8QoX8PVF5Jid9e9NPRINwMuMZoeS3vhrf0RjJ/o1PKin4pBpPkr6Gz+9+UczQLvTgD3oZc+wR6YN0MoWa53SRJhxInGPNS6KPi6hXsUpKWXcxgfnx24FETUsamOUhLeObJUyNPnSfbB3xrv4X5Oe5PpT9JI8B2+OSdeeFPxILu8kvMOjg7ZFHNkjnOJey37HxHqPGIEP3M3LGPg3NrUBmw5uEOJKZxaUNGIcpc3TwR3ulVfyX4lVDpSqwutclBkEkzNOMYhHLFViZANt8FYMtzr1YFqINI1ZNCRvwIeFSpcbhXSh3vvC8eXedh+GRZO/Q== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MW2PR12MB4666.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(4636009)(366004)(64756008)(53546011)(76116006)(66476007)(66946007)(66556008)(7696005)(6506007)(52536014)(8936002)(33656002)(8676002)(4326008)(66446008)(86362001)(5660300002)(83380400001)(38070700005)(38100700002)(55016003)(71200400001)(2906002)(122000001)(186003)(508600001)(110136005)(26005)(9686003)(316002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?3TocbNxjxT6A2bnqxUFVQt2S5x7muepEHlf4jjH4IZkI1SUz3AaveSfO13+p?= =?us-ascii?Q?+i6mRwr1U/1twm+4jd1XlKJRNy+aMTuf6eOqdGzLu9l9J9/L70CzOHSsICGv?= =?us-ascii?Q?MxoBT4lArphwfKO6gUYHGo8DWJ2AAs1il7ZPCkQ+5ZaXriVXuyA41TsiFi+V?= =?us-ascii?Q?lS3oSAKwXvk1UulwDUelxbIB0RZs4DkHVwoHkr3lczmuPJNgwdKf/KMLskyi?= =?us-ascii?Q?YTF6AGIrqfpy6CVDEd68mpA47E+/EYmcvDD0YkYzV+rQcikn2kWkt0bGqvAz?= =?us-ascii?Q?y9/P2k4D7/zeRQqbWMTnhv1Gud4+j+hHQazA7Llb7SixJbIUTuN+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Um3B8/i3Uoth3X6anV7MKfBgmqmyOJlpih4G8E?= =?us-ascii?Q?lH2PFIwsa/XnKMAenYlkYA80ALPac9TrAp4Xwr5tFJFIUClGhsJcaukSRJLa?= =?us-ascii?Q?Zb4vWhDWLdPZgd7HAFbveS6B2OsYmtbyhr1VcW05xOhYhHU4Nv5379Py9jGJ?= =?us-ascii?Q?v1Mjru/qsxGrJ5CKcWMUacebscK4JjqeKrFDpcxHz5JnFgKz8AqBax+xbMrg?= =?us-ascii?Q?DOM/oW5r5KoHKKUEEvNRCI3WMU++4juoh+uGbnJ+NEi6UxraLmpOM93LOjBU?= =?us-ascii?Q?MBkKS8tH/Se5Y3IGr9/8ZSL9on9RJL9s1QxyYPBseH7vuSVFwXMkK/qkp3X5?= =?us-ascii?Q?Cl3vdeJ55YyV/nV3nn9d2a8vb6fiFLHhVu+aYNTGD9nbeK7L0kNoojSOE2Tf?= =?us-ascii?Q?QTTf3PoVbGDiBDZodToD3BL3Tf+1XcZgGA3epFt20S6LnQ+2b48Lx0Y7tuD6?= =?us-ascii?Q?ScqADkYYj6bNk1ghMHFwjwDXTNywNsJ4pp1m93ZS143EuTBZ?= 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: MW2PR12MB4666.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: ef3e7368-6209-4df5-b2ab-08da18899d68 X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Apr 2022 11:27:35.5879 (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: ZM7Kf4vVMx4gewEq6GehQRIqDydNqmJOWaltE2pvSa8vnvOMvQdMQN//Cmsn9YJ4BRqXHJey/NqR5FLmePqsCA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB4743 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 Hi Jack, > -----Original Message----- > From: Jack Min > Sent: Thursday, April 7, 2022 8:31 AM > Subject: [RFC 1/2] ethdev: port flags for pre-configuration flow hints >=20 > The data-path focused flow rule management can manage flow rules in more > optimized way then tranditional one by using hits provided by > application in initialization phase. >=20 > In addition to the current hints we have in port attr, more hints could > be proivded by application about it's behaviour. >=20 > One example is how the application do with the same flow: > A. create/destroy flow on same queue but query flow on different queue > or queue-less way (i.e, counter query) > B. All flow operations will be exactly on the same queue, by which PMD > could be in more optimized way then A because resource could be > isolated and access based on queue, without lock for example. >=20 > This patch add flag about above situation and could be extanded to cover > more situations. >=20 > Signed-off-by: Xiaoyu Min > --- > lib/ethdev/rte_flow.h | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) >=20 > diff --git a/lib/ethdev/rte_flow.h b/lib/ethdev/rte_flow.h > index d8827dd184..578dd837f5 100644 > --- a/lib/ethdev/rte_flow.h > +++ b/lib/ethdev/rte_flow.h > @@ -4875,6 +4875,17 @@ rte_flow_flex_item_release(uint16_t port_id, > const struct rte_flow_item_flex_handle *handle, > struct rte_flow_error *error); >=20 > +/** > + * The flags of rte flow port > + */ > +enum rte_flow_port_flag { > + /** > + * All flow operations for one specified flow will _strictlly_ happen > + * on the same queue (create/destroy/query/update). > + */ > + RTE_FLOW_PORT_FLAG_STRICT_QUEUE =3D RTE_BIT32(0), > +}; > + > /** > * @warning > * @b EXPERIMENTAL: this API may change without prior notice. > @@ -4972,6 +4983,11 @@ struct rte_flow_port_attr { > * @see RTE_FLOW_ACTION_TYPE_METER > */ > uint32_t nb_meters; > + /** > + * Port flags. > + * @see enum rte_flow_port_flag > + */ > + enum rte_flow_port_flag flags; Why the use of enum and not flags? I guess there will be more flags in future, and those flags will not be rel= ated to the strict queue. > }; >=20 > /** > -- > 2.35.1