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 6705AA0564; Fri, 12 Mar 2021 02:45:00 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 15B264067E; Fri, 12 Mar 2021 02:45:00 +0100 (CET) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by mails.dpdk.org (Postfix) with ESMTP id 225474014D for ; Fri, 12 Mar 2021 02:44:57 +0100 (CET) IronPort-SDR: n+oSIFxcsdpuXraeATmNf1V1MknQDoLOkesYBkc/DjB1vAfmohFlYW2br5tyHWUlXODczDCdsJ PCINzOgYOWJw== X-IronPort-AV: E=McAfee;i="6000,8403,9920"; a="168041726" X-IronPort-AV: E=Sophos;i="5.81,241,1610438400"; d="scan'208";a="168041726" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Mar 2021 17:44:55 -0800 IronPort-SDR: ecq8ySIwmk9SmRbPkPG2ErElYSEyMKzPu4qYn/T+p7G/Q5UPLlhjaZge3hWSUWnsMXebe+iDwd fwXeQvfDhWUQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.81,241,1610438400"; d="scan'208";a="600433636" Received: from fmsmsx606.amr.corp.intel.com ([10.18.126.86]) by fmsmga006.fm.intel.com with ESMTP; 11 Mar 2021 17:44:55 -0800 Received: from fmsmsx609.amr.corp.intel.com (10.18.126.89) by fmsmsx606.amr.corp.intel.com (10.18.126.86) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2106.2; Thu, 11 Mar 2021 17:44:54 -0800 Received: from fmsmsx602.amr.corp.intel.com (10.18.126.82) by fmsmsx609.amr.corp.intel.com (10.18.126.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2106.2; Thu, 11 Mar 2021 17:44:54 -0800 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) by fmsmsx602.amr.corp.intel.com (10.18.126.82) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2106.2 via Frontend Transport; Thu, 11 Mar 2021 17:44:54 -0800 Received: from NAM11-BN8-obe.outbound.protection.outlook.com (104.47.58.176) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2106.2; Thu, 11 Mar 2021 17:44:51 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LAtsZOiK8/I6S9ZMNwyceS9xm1dqHoiolvvcrhF/NeU92LzGNrOvv4AhkXRrM5HWxL7UAa22cVG/YK4TwjL9Y9qweHOPXLyqv4HrTZfgXoysOt/xF7ewJE75xweHJkZDxOQdogy2RFwMXFfnfSgCb8lCGlK493YciO5uDr5CrKthtqkh6CKZtFppEhxdWvZtSe0zs7/co1YsREYOmCGDLgaTGqkSWklJgfwSGiG/mUzvmR0UCdwrQjUKgPyLDjN2yOR8CkuX3aFEgqpTXju+pcl30lmZAromwsgrQXN80WB6ae+QdVu9A97JODKhD4JtNygY9YfUCCCxaZYVUJzD+A== 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=KjOPQKXelB5AVCLm7eu+oKsK5JqL2syC0QFmJOltW1s=; b=DE6CUbO1vPwNyOd6101EXMbImDs9umnesxL4XTMjP/Chn53D3c5vxTZ0d5W/Ar39lXyK5AcOJv8ws7n3eQtgCJYRoU83uEbKOLMVsxHepXt17LEoVCBkW65F7ZUyct2z/IuKEbsWr6rl24WohPb2BpqFNl/XzHTgYPyvWKTJpDFxFxIq7Eq2YFeCioDn870PNYxPBCEIJOXrSeSMbBJn4UvDmzPcskT8xFKDhH/OWU8q3SZ9sEKH3mjhMlswo3GdQuHzM9fkx3Nse/yMxOJNQ3vOXCSRHl/JnWyccCS6SxsfdSO+ph80Az1bBUoXXhZuTVOR4I1PTvjmA9NT5clnsg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=KjOPQKXelB5AVCLm7eu+oKsK5JqL2syC0QFmJOltW1s=; b=lXR1QmRCzn7dfwkZVw4XKmQWoj4tIOujrz5h0CIdu7raWo+pjhRqNsG8rjvlnRSM/YZjQteJBvh/8FZ77nAqIzXgmtWMN3iEvEbLRn6IpzWTcvyQrQbkh9oN/otZLF6VaBGsYQVHKDQbhV1RnOET16/pYw9Y/tTt4JtqgckCL/E= Received: from BN8PR11MB3795.namprd11.prod.outlook.com (2603:10b6:408:82::31) by BN9PR11MB5289.namprd11.prod.outlook.com (2603:10b6:408:136::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3933.31; Fri, 12 Mar 2021 01:44:42 +0000 Received: from BN8PR11MB3795.namprd11.prod.outlook.com ([fe80::ec6a:25a8:8c59:89e]) by BN8PR11MB3795.namprd11.prod.outlook.com ([fe80::ec6a:25a8:8c59:89e%2]) with mapi id 15.20.3912.027; Fri, 12 Mar 2021 01:44:42 +0000 From: "Wang, Haiyue" To: Thomas Monjalon , "dev@dpdk.org" CC: Ori Kam , Ajit Khaparde , Somnath Kotur , Chas Williams , "Min Hu (Connor)" , Rahul Lakkireddy , Hemant Agrawal , Sachin Saxena , "Guo, Jia" , "Daley, John" , Hyong Youb Kim , Gaetan Rivet , Ziyang Xuan , "Xiaoyun Wang" , Guoyang Zhou , Yisen Zhuang , Lijun Ou , "Xing, Beilei" , "Wu, Jingjing" , "Yang, Qiming" , "Zhang, Qi Z" , "Xu, Rosen" , Matan Azrad , "Shahaf Shuler" , Viacheslav Ovsiienko , Liron Himi , Jerin Jacob , "Nithin Dabilpuram" , Kiran Kumar K , Rasesh Mody , Shahed Shaikh , Andrew Rybchenko , "Singh, Jasvinder" , "Dumitrescu, Cristian" , "Wiles, Keith" , Jiawen Wu , Jian Wang , "Yigit, Ferruh" Thread-Topic: [PATCH 1/2] ethdev: replace callback getting filter operations Thread-Index: AQHXFsR2q6Y5A4ET90iwwDKdyBUkVap/kdzg Date: Fri, 12 Mar 2021 01:44:42 +0000 Message-ID: References: <20210311221742.3750589-1-thomas@monjalon.net> <20210311221742.3750589-2-thomas@monjalon.net> In-Reply-To: <20210311221742.3750589-2-thomas@monjalon.net> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.6.0.76 authentication-results: monjalon.net; dkim=none (message not signed) header.d=none;monjalon.net; dmarc=none action=none header.from=intel.com; x-originating-ip: [192.102.204.36] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 4525a8ea-6dd2-4a60-1b20-08d8e4f86841 x-ms-traffictypediagnostic: BN9PR11MB5289: x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1122; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: PzISTTyQhLDwCM++8TrYyd+soV1Gmps/FD79aufVkyhvTA8Vihi5RhxOHD5JSpvJhbzOl4z46i3o/NjTu4S5AfmulI2tT315Poj0lEDRdaophhePVQrqP8Xs9378wyuNH1S6vamyrtt3o06Hup05cJNQhkl+S01mHWT5n6fSSTYweC4jtC1jkXjvOpE4sTBVj7txFBo/kVAoURoKiIuUj1koHPdVgKv1dFuxT+BApPvHQuf6tkBieBEaVyGupC1gm1DbOrqFy+ioHNht1RwQVJXAigHpo0/FuVD/GkGXS8QnhCr1FdccDuXV6QLMElVDnDWxcU7Lt6Mn0ApBZ0SxAu1HaHE/D8H4UCbzjHLB+pcrcliCUZTG5vwv3803TOgOr3d6jICPiFwgXOUKi3bBnJxCXzjG0WEh00J0Uk6RI+Qxmu6rf5dYNWjAEBf6k/DHLt5H18cx8AIBXvV7xj4cumCFNlgbBEwvdZ1shnR24USt66C5lwExszvktVvnz309OnteR/I4LNW2tDHSLY5rL1TdN/yHq+djb0T/hZOUC8sXwoxtDoUaWUy824EvjuYK x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BN8PR11MB3795.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(39860400002)(376002)(346002)(396003)(136003)(66446008)(66556008)(478600001)(55016002)(76116006)(8676002)(316002)(8936002)(26005)(5660300002)(186003)(54906003)(110136005)(53546011)(66946007)(66476007)(4326008)(64756008)(107886003)(9686003)(71200400001)(6506007)(7416002)(7406005)(52536014)(2906002)(7696005)(33656002)(86362001)(83380400001); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?XwYo3vsa+XzatFWV7HqeOQ2EP18H6d4qC3pKZT6tutEm0hvIv8xPPC/1Wo91?= =?us-ascii?Q?iVrszHagc9O786TZg8AyxXP1cncjRPoDu2x9rp9EGRz/x6BZ+n/UmAWgeYqn?= =?us-ascii?Q?CGZ8QZDguHpQaeZY1XXF6xrzI7bMpKzMw61s1tqBxMIzT8GBQMg9hkKyiSW1?= =?us-ascii?Q?wcj1IZjvrfE5Mc7izwRrGEK7BDqeXntEgfP7hQ5ny/F0ZGySL2hedHazOb7t?= =?us-ascii?Q?rNht+NhaQWUXc1aOhHSCimPEKpLtF7Dg309ul1n5Vaq0/ut6/7x24VkNOMdb?= =?us-ascii?Q?H/I3tbBo3YGNUO84CY35TfUX9RmsLJ4Npc0+s397QWwmSLy5t0GnLvHUbHJE?= =?us-ascii?Q?r7c5acEXtDDaVWk2tSmMSO+HE+982B+bPym/nDroh0oT3LQAa8Q8iditSleN?= =?us-ascii?Q?TKAxsAGiC7JHeSvM6uCAYkKfmIBe3COKcgWGukPdPucivU9yT8mJuRFZicZl?= =?us-ascii?Q?Lr/AttsNjcbFzU2to1XC77cbCa+H0OhO9rUiSx33VHNM24L8llqQpH8u4le7?= =?us-ascii?Q?Nds3ezlF0TM/KecUrXO1Iny6B1eCGtNf3zm181YuWvMeJV7ZWn9sppLKnrEq?= =?us-ascii?Q?WNHXchR5F4hTx6oL4DXL5ZmJJpVFNbhHYm/zHK8IM8ziodbQgD5RyXIT7qti?= =?us-ascii?Q?1yvuWhyOSMKo/d/esx9V9564x/verijHscQLz8pbtzn699QpJW8o66cb69dI?= =?us-ascii?Q?acvNwWhgW7C02kPsaRaVxDreeYJ3q39JwryLe/8piRF+PhUczvmCs1dEv4h6?= =?us-ascii?Q?4Nb+VPZ+rVcXeVUzBi9BVLkToYCKRAmsp3mX/mnOLtG1z2cDCNiWJLDSr5rI?= =?us-ascii?Q?9CGc0AXwWSqTGP3kQYDraE0WObSgru1C9ZGY5OD7ehKgH2MXXdoibZsQS4Kx?= =?us-ascii?Q?ivfa1Lvo58E7OqFupWJ8nuR9qKB0pGHxmxB25vlGuqsBs7mPnP3e6R4x3/Yq?= =?us-ascii?Q?nbznekf+c/oQZrBBH3U6HD0vKMyMnlirelMV6v3KiK2E+bSAFYytQv/fZG2L?= =?us-ascii?Q?WDPORhPvf5unbxvgV3sVvoMNCr68Wei7tJeBA2RaFvOUPc/LQgFX74rsiMUI?= =?us-ascii?Q?jVF9GLIuby7BmOA6Z3Nmp7KL8A2JV5wH/RqamRkrCEOOfXhl5W4+S4otUwrJ?= =?us-ascii?Q?UpAVWYI0gzF9vA7Bq+CkdxaciHVrwMr3fPxpTtLVFW8q4G6qsnuztUs+p1K0?= =?us-ascii?Q?Tj7jYKTegn0pU1quXcu7I4VL6G5e0pO87YV99Zc1ccQJSIgxLiFomICEuP8w?= =?us-ascii?Q?uUK4PihH1GPy/QLWf0ooccE/9266N2KWwwt9mOa2pU/I+UgTcAp2wGvDLYFk?= =?us-ascii?Q?SrecrxA6umrqM/vFPYdYVCBl?= 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: BN8PR11MB3795.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4525a8ea-6dd2-4a60-1b20-08d8e4f86841 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Mar 2021 01:44:42.2706 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: qKAYN87G8bYGr/Ezb1NwXN6zJZyfi3NGLdPWk0GRHFOfuNvpHDffYNuPkEi8IYLdaGRRTRatR7CrXINd2CP9sw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN9PR11MB5289 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH 1/2] ethdev: replace callback getting filter operations 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: Thomas Monjalon > Sent: Friday, March 12, 2021 06:18 > To: dev@dpdk.org > Cc: Ori Kam ; Ajit Khaparde ; Somnath Kotur > ; Chas Williams ; Min Hu (Conn= or) ; > Rahul Lakkireddy ; Hemant Agrawal ; Sachin > Saxena ; Guo, Jia ; Wang, H= aiyue ; > Daley, John ; Hyong Youb Kim ; Gae= tan Rivet ; > Ziyang Xuan ; Xiaoyun Wang ; Guoyang Zhou > ; Yisen Zhuang ; Lijun O= u ; Xing, > Beilei ; Wu, Jingjing ; Yan= g, Qiming > ; Zhang, Qi Z ; Xu, Rosen ; Matan > Azrad ; Shahaf Shuler ; Viacheslav = Ovsiienko > ; Liron Himi ; Jerin Jacob ; Nithin > Dabilpuram ; Kiran Kumar K ; Rasesh Mody > ; Shahed Shaikh ; Andrew Rybchen= ko > ; Singh, Jasvinder ; Dumitrescu, Cristian > ; Wiles, Keith ; Ji= awen Wu > ; Jian Wang ; Yigit, Fe= rruh > Subject: [PATCH 1/2] ethdev: replace callback getting filter operations >=20 > Since rte_flow is the only API for filtering operations, > the legacy driver interface filter_ctrl was too much complicated > for the simple task of getting the struct rte_flow_ops. >=20 > The filter type RTE_ETH_FILTER_GENERIC and > the filter operarion RTE_ETH_FILTER_GET are removed. > The new driver callback flow_ops_get replaces filter_ctrl. >=20 > Signed-off-by: Thomas Monjalon > --- > doc/guides/nics/features.rst | 4 +-- > doc/guides/prog_guide/rte_flow.rst | 14 +------- > doc/guides/rel_notes/release_20_11.rst | 2 +- > doc/guides/rel_notes/release_2_2.rst | 2 +- > drivers/net/bnxt/bnxt.h | 6 ++-- > drivers/net/bnxt/bnxt_ethdev.c | 40 +++++++-------------- > drivers/net/bnxt/bnxt_reps.c | 2 +- > drivers/net/bonding/rte_eth_bond_pmd.c | 13 +++---- > drivers/net/cxgbe/cxgbe_ethdev.c | 2 +- > drivers/net/cxgbe/cxgbe_flow.c | 22 +++--------- > drivers/net/cxgbe/cxgbe_flow.h | 7 ++-- > drivers/net/dpaa2/dpaa2_ethdev.c | 44 +++-------------------- > drivers/net/dpaa2/dpaa2_flow.c | 29 +++++----------- > drivers/net/e1000/igb_ethdev.c | 31 ++++------------- > drivers/net/enic/enic_ethdev.c | 30 +++++----------- > drivers/net/enic/enic_vf_representor.c | 33 ++++++------------ > drivers/net/failsafe/failsafe_ops.c | 16 +++------ > drivers/net/hinic/hinic_pmd_ethdev.c | 36 ++++--------------- > drivers/net/hns3/hns3_ethdev.c | 2 +- > drivers/net/hns3/hns3_ethdev.h | 5 ++- > drivers/net/hns3/hns3_ethdev_vf.c | 2 +- > drivers/net/hns3/hns3_flow.c | 30 ++++------------ > drivers/net/i40e/i40e_ethdev.c | 32 ++++------------- > drivers/net/iavf/iavf_ethdev.c | 32 ++++------------- > drivers/net/ice/ice_dcf_ethdev.c | 27 +++------------ > drivers/net/ice/ice_ethdev.c | 32 ++++------------- > drivers/net/igc/igc_ethdev.c | 2 +- > drivers/net/igc/igc_filter.c | 23 +++---------- > drivers/net/igc/igc_filter.h | 5 ++- > drivers/net/ipn3ke/ipn3ke_representor.c | 28 ++++----------- > drivers/net/ixgbe/ixgbe_ethdev.c | 32 ++++------------- > drivers/net/mlx4/mlx4.c | 2 +- > drivers/net/mlx4/mlx4_flow.c | 32 ++++------------- > drivers/net/mlx4/mlx4_flow.h | 5 +-- > drivers/net/mlx5/mlx5.c | 4 +-- > drivers/net/mlx5/mlx5.h | 5 +-- > drivers/net/mlx5/mlx5_flow.c | 32 ++++------------- > drivers/net/mvpp2/mrvl_ethdev.c | 26 ++++---------- > drivers/net/octeontx2/otx2_ethdev.c | 2 +- > drivers/net/octeontx2/otx2_ethdev.h | 5 ++- > drivers/net/octeontx2/otx2_ethdev_ops.c | 21 +++-------- > drivers/net/qede/qede_ethdev.c | 2 +- > drivers/net/qede/qede_ethdev.h | 7 ++-- > drivers/net/qede/qede_filter.c | 27 ++++----------- > drivers/net/sfc/sfc_ethdev.c | 31 +++-------------- > drivers/net/softnic/rte_eth_softnic.c | 17 +++------ > drivers/net/tap/rte_eth_tap.c | 2 +- > drivers/net/tap/tap_flow.c | 27 ++++----------- > drivers/net/tap/tap_flow.h | 6 ++-- > drivers/net/txgbe/txgbe_ethdev.c | 26 +++----------- > lib/librte_ethdev/ethdev_driver.h | 46 +++++++++---------------- > lib/librte_ethdev/rte_eth_ctrl.h | 2 +- > lib/librte_ethdev/rte_flow.c | 9 ++--- > lib/librte_ethdev/rte_flow_driver.h | 25 -------------- > 54 files changed, 226 insertions(+), 720 deletions(-) >=20 > -enum rte_filter_op { > - RTE_ETH_FILTER_GET, /**< get flow API ops */ > -}; > - > -typedef int (*eth_filter_ctrl_t)(struct rte_eth_dev *dev, > - enum rte_filter_type filter_type, > - enum rte_filter_op filter_op, > - void *arg); > -/**< @internal Take operations to assigned filter type on an Ethernet de= vice */ > +struct rte_flow_ops; > +typedef int (*eth_flow_ops_get_t)(struct rte_eth_dev *dev, > + const struct rte_flow_ops **ops); > +/**< @internal Get flow operations */ >=20 How about to change the return type to "const struct rte_flow_ops *" direct= ly ? typedef const struct rte_flow_ops * (*eth_flow_ops_get_t)(struct rte_eth_de= v *dev); > -- > 2.30.1