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 58E3BA0C43; Wed, 20 Oct 2021 14:20:54 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DF07340687; Wed, 20 Oct 2021 14:20:53 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mails.dpdk.org (Postfix) with ESMTP id 665F940142 for ; Wed, 20 Oct 2021 14:20:52 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10142"; a="215930682" X-IronPort-AV: E=Sophos;i="5.87,166,1631602800"; d="scan'208";a="215930682" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Oct 2021 05:20:51 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.87,166,1631602800"; d="scan'208";a="491251175" Received: from orsmsx605.amr.corp.intel.com ([10.22.229.18]) by fmsmga007.fm.intel.com with ESMTP; 20 Oct 2021 05:20:50 -0700 Received: from orsmsx611.amr.corp.intel.com (10.22.229.24) by ORSMSX605.amr.corp.intel.com (10.22.229.18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12; Wed, 20 Oct 2021 05:20:50 -0700 Received: from orsmsx606.amr.corp.intel.com (10.22.229.19) by ORSMSX611.amr.corp.intel.com (10.22.229.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12; Wed, 20 Oct 2021 05:20:49 -0700 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx606.amr.corp.intel.com (10.22.229.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12 via Frontend Transport; Wed, 20 Oct 2021 05:20:49 -0700 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.170) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2242.12; Wed, 20 Oct 2021 05:20:49 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JofRHwXrj/QHELulp87eSROqB/mYfN7HqMsep6XEhNZnWddJ3jwv3wwwtjYMTu5FgG6pZGbzbbQvhRKttsBpSUQyDjtJPHzz1dykPUoPrutJdSs6oQTTBmvWYxjAjdsWiHqXEDzX/l+IIZD3ESzADVWZW9koZySPI1CMnDwHPwL+9w1B+OAJG5GEfEvKJ90olCOpqYuNskhJR97EwBgYHa7trbMDgeslmsbnGvGe1lM0LUqRCJmNOtWFDvPBBifuXeNKzsDKx0chBvRBA/WAGKM5VcMlko3MdnSbLQKCDAXlgCHmLjpUGNDiXBDSq3Skk1LvaZbpWTeVqzs+cO5B0w== 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=rBkM+zAH1MkFrkAEm3DskzO/LE/PCB6NdqFYuzOzymc=; b=alKhgVIl5MhrXPSr4sbXnYLYk74nVGOl8Dy74nP7mGJ/fP3MIc09u77xOLeevZUQWm76/0RrmdCPWv6sTjltcD+rAStAQ011D/QMBtNJa0k/Wu/Rtq0DKBWo3FoMtSyL8vqlmUhiIWydCtpizZKDMBWSMKPJvwoFRs15lknHNppVg+4fl8pBLHzTWisTqKVzpdVFf5LhzOVpLv2eGYfYiPQcnvPen0VgOeI9mgp6Bs6uWqGDRW1om++NdYOSaJeukV2rioEZU+NyrSqU69B6D3i3UvObyL7v1Vy/8CCnGzHk9DCn1Ez4qi6vBvpTyv0aFycNzgfYr/YvvOxcBD6KJw== 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=rBkM+zAH1MkFrkAEm3DskzO/LE/PCB6NdqFYuzOzymc=; b=l0uxRxUHpKMnYFn+HB/++IeByEwhXGg5WChc9fjvbAjBIjDqkWYq66/aO+UKtPf9gF50WY/LISvFWkfv/uR20Mrz4c5rEhxXKVUD1scGDHJK/2snSLlRXtgclnTSOIhDwldHbr47K5l+FEsq+Ki85W2hOO3JJr3RFa3JjX0bjNg= Received: from BY5PR11MB4482.namprd11.prod.outlook.com (2603:10b6:a03:1ca::33) by BYAPR11MB3094.namprd11.prod.outlook.com (2603:10b6:a03:87::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4608.16; Wed, 20 Oct 2021 12:20:48 +0000 Received: from BY5PR11MB4482.namprd11.prod.outlook.com ([fe80::30b7:5052:a6c2:9023]) by BY5PR11MB4482.namprd11.prod.outlook.com ([fe80::30b7:5052:a6c2:9023%4]) with mapi id 15.20.4608.018; Wed, 20 Oct 2021 12:20:48 +0000 From: "Ananyev, Konstantin" To: "Zhang, Roy Fan" , Akhil Goyal , "dev@dpdk.org" CC: "thomas@monjalon.net" , "david.marchand@redhat.com" , "hemant.agrawal@nxp.com" , "anoobj@marvell.com" , "De Lara Guarch, Pablo" , "Trahe, Fiona" , "Doherty, Declan" , "matan@nvidia.com" , "g.singh@nxp.com" , "jianjay.zhou@huawei.com" , "asomalap@amd.com" , "ruifeng.wang@arm.com" , "Nicolau, Radu" , "ajit.khaparde@broadcom.com" , "rnagadheeraj@marvell.com" , "adwivedi@marvell.com" , "Power, Ciara" Thread-Topic: [PATCH v4 4/8] crypto/scheduler: use proper API for device start/stop Thread-Index: AQHXxaWrZ3UOBcAUVk+oZGWZZ6mT66vbwOCAgAANa6A= Date: Wed, 20 Oct 2021 12:20:48 +0000 Message-ID: References: <20211018144201.2028022-1-gakhil@marvell.com> <20211020112754.1270163-1-gakhil@marvell.com> <20211020112754.1270163-5-gakhil@marvell.com> In-Reply-To: Accept-Language: en-GB, 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.200.16 authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: f11d0101-9635-4cd9-99eb-08d993c40c84 x-ms-traffictypediagnostic: BYAPR11MB3094: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1002; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: ZyFZqkWEoYy45bw/iUh3Om89yPAkUmZtKq5BYDrM5/3dSiJZYiO+9GB+sCp1Rlzva1rTB0LBKrhXmiQxrq42gAhdd8k9Jqwu0KYf54C6c89syg/Y9VXBnS1/rNSK6F96hihC323Q9l+Hsh/lBoeNNj+hWq8pVLhlqCN0qyXIuYZ/2NqfsIv994twezeRWWYYqmazJo5db8AH5Gy24YOS6iVsIenMAt0m0vPQ6lUTOZsFky49HY0AG6p/5nBAFV9daV4VxnLWxHxhHPf/j0sYiwLY3tJrEYF01y7UiHssvQAhPTh2JO7sDJxYM4+Csm5YKR/jiP7BFL/ST5o9vyyQ6tX0M8++prhteEKViBxmIqmqbSOTf1ZbltkHrjLCoKjL17dDRT2T3c6sES+GKjgXG3Bwz8oGuVksnC7XPRWmbII/bBpxln2K103G9kEcikvWjHzHaSmMDSXDk/YSk1qPu+A2tOUCRHoJMayDbdEhxATSXLtdF1jQvRzu3pirdaXSMbrTSmNe34xuLnKVFjBc0hSyazxp0cRWbZIYygO/B4SzydfUaIHwGmgwQOWOHVYNDbTTDmqmJdVXmgQyrELSSmsfnEcjSRmYTJjpBClJ1m/2PlJVu/g4srjIg7t42Nwg2KHcLHI839DKsQ33ti9afDm6+yHUvumSEgI8dSi4vDj2PbDaYHg8g9x4jxDrmAIVKvFpL4OFVAMSQfxuCsok9Q== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BY5PR11MB4482.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(8676002)(71200400001)(38100700002)(316002)(54906003)(110136005)(66946007)(76116006)(107886003)(64756008)(66556008)(86362001)(52536014)(66446008)(66476007)(8936002)(5660300002)(122000001)(4326008)(38070700005)(9686003)(55016002)(6506007)(82960400001)(33656002)(7416002)(55236004)(2906002)(26005)(83380400001)(186003)(508600001)(7696005); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?iaTUHWFTTlnBNR89nxyrCHca5twKjTi6e4dYgryybtYFFzs14QV/i4i9XoBU?= =?us-ascii?Q?VbPelU+xZraBfcE/bsNZfwap6/aLIvxHBd7vpXIK2FdDWZXczWJlubIMu3mF?= =?us-ascii?Q?fRR9NvXMdRIh3zbf7gGsu2wy/Fo0IWoULHOiZlnUd1pinTMXzKhtzGcJ3Hlh?= =?us-ascii?Q?6yzXyNm1Ov79Kko1raLmhWbmWaDrjaEUETiNuX59U3BqkC3oPXx8c6c3SmLy?= =?us-ascii?Q?DFhNj4kNB+pdMG1GUnzuXt97ZaatV/TWOWSprvFjf1IA6jl9TLa5hZ0a46Lx?= =?us-ascii?Q?RocM71YMSJ1fKUR9+RnTLlNTNJSWZ1c10GT1F5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-ascii?Q?4TZI0Yn0WwHKyfmnDpgxtzf6z38lcB5dYopSEHMqoTgY5KiqYHKL/abfsjiA?= =?us-ascii?Q?udT8MSP/wwgfr2aQlvJjSf9kI+qV5A642Wceeiu9maq+TA065MzC/EWZoCRH?= =?us-ascii?Q?jyE7ZdNeRGnBHR5G/QMhMvm1?= 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: BY5PR11MB4482.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: f11d0101-9635-4cd9-99eb-08d993c40c84 X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Oct 2021 12:20:48.1056 (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: konstantin.ananyev@intel.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR11MB3094 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH v4 4/8] crypto/scheduler: use proper API for device start/stop 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" > > The worker PMDs were using direct device start/stop > > functions rather than rte_cryptodev_start(), > > so rte_crypto_fp_ops never get set. This patch calls > > the rte_cryptodev_start and stop APIs which start and > > stop devices properly and fp_ops get set. > > > > Reported-by: Ciara Power > > Signed-off-by: Akhil Goyal > > --- > > drivers/crypto/scheduler/scheduler_pmd_ops.c | 9 ++------- > > 1 file changed, 2 insertions(+), 7 deletions(-) > > > > diff --git a/drivers/crypto/scheduler/scheduler_pmd_ops.c > > b/drivers/crypto/scheduler/scheduler_pmd_ops.c > > index 465b88ade8..f61640c9d6 100644 > > --- a/drivers/crypto/scheduler/scheduler_pmd_ops.c > > +++ b/drivers/crypto/scheduler/scheduler_pmd_ops.c > > @@ -181,10 +181,7 @@ scheduler_pmd_start(struct rte_cryptodev *dev) > > /* start all workers */ > > for (i =3D 0; i < sched_ctx->nb_workers; i++) { > > uint8_t worker_dev_id =3D sched_ctx->workers[i].dev_id; > > - struct rte_cryptodev *worker_dev =3D > > - > > rte_cryptodev_pmd_get_dev(worker_dev_id); > > - > > - ret =3D (*worker_dev->dev_ops->dev_start)(worker_dev); > > + ret =3D rte_cryptodev_start(worker_dev_id); > > if (ret < 0) { > > CR_SCHED_LOG(ERR, "Failed to start worker dev %u", > > worker_dev_id); > > @@ -208,10 +205,8 @@ scheduler_pmd_stop(struct rte_cryptodev *dev) > > /* stop all workers first */ > > for (i =3D 0; i < sched_ctx->nb_workers; i++) { > > uint8_t worker_dev_id =3D sched_ctx->workers[i].dev_id; > > - struct rte_cryptodev *worker_dev =3D > > - > > rte_cryptodev_pmd_get_dev(worker_dev_id); > > > > - (*worker_dev->dev_ops->dev_stop)(worker_dev); > > + rte_cryptodev_stop(worker_dev_id); > > } > > > > if (*sched_ctx->ops.scheduler_stop) > > -- > > 2.25.1 > Acked-by: Fan Zhang Acked-by: Konstantin Ananyev