From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-CY1-obe.outbound.protection.outlook.com (mail-cys01nam02on0058.outbound.protection.outlook.com [104.47.37.58]) by dpdk.org (Postfix) with ESMTP id A97E071B3 for ; Tue, 23 Jan 2018 12:58:13 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=xIrpdho4Geh50/UpgRwEksUou4dKipOJAPsl2nd7Djg=; b=aQeGAJ6UE6m0HpJL53xcRGkpAF4SzPG+SjKGucAw6H0vZHYpQxtw8CHBhGarRaTjJDRBt7kFSOuR2OLkxmZp4cdKmaH1dlsDy/2cVHHlB4+9mx6GpkAt/7x/Dc0tZfTY2jtAuvL0iA8lAB2Gz6ZkImbuxDZqPf4AsAe6CBr3pko= Received: from BY1PR0701MB1111.namprd07.prod.outlook.com (10.160.104.21) by MWHPR07MB3072.namprd07.prod.outlook.com (10.172.97.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.428.17; Tue, 23 Jan 2018 11:58:11 +0000 Received: from BY1PR0701MB1111.namprd07.prod.outlook.com ([fe80::e040:3b79:6671:b66a]) by BY1PR0701MB1111.namprd07.prod.outlook.com ([fe80::e040:3b79:6671:b66a%14]) with mapi id 15.20.0428.019; Tue, 23 Jan 2018 11:58:08 +0000 From: "Verma, Shally" To: "Trahe, Fiona" , "dev@dpdk.org" , "akhil.goyal@nxp.com" CC: "Challa, Mahipal" , "Athreya, Narayana Prasad" , "De Lara Guarch, Pablo" , "Gupta, Ashish" , "Sahu, Sunila" , "Jain, Deepak K" , Hemant Agrawal , Roy Pledge , Youri Querry , Ahmed Mansour Thread-Topic: [RFC v3 1/1] lib: add compressdev API Thread-Index: AQHTdc0Olvrvx8Spo02l2PHMHF7TgqN5vSMggAGRWYCABjWfkA== Date: Tue, 23 Jan 2018 11:58:08 +0000 Message-ID: References: <1511542566-10455-1-git-send-email-fiona.trahe@intel.com> <1513360153-15036-1-git-send-email-fiona.trahe@intel.com> <348A99DA5F5B7549AA880327E580B435892FCF50@IRSMSX101.ger.corp.intel.com> In-Reply-To: <348A99DA5F5B7549AA880327E580B435892FCF50@IRSMSX101.ger.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Shally.Verma@cavium.com; x-originating-ip: [115.113.156.2] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; MWHPR07MB3072; 7:6rcaFxHmzCrHxnI+II+3+sOGPBXW6rdaK3i5u2lweISci9bPlJmXnLQcafkGPaHd73I4zTL8pFTY0xp0yz4irV4VXDG/xzx7O0uyD/XzE9IXTjBacheiQIv9auaxIeJWbJytJEWqoK/hQnDbLntK0AqqjlDNRraOLPsN1N3dBlWlVxuCc/Ms2HaAk7BTCbIa4I2kU6gZEH101LmsE6Sw61I1VQ0M0f7VpQjr0xgcH9i5ziuqHRkVBJaiy2EnlzJi x-ms-exchange-antispam-srfa-diagnostics: SSOS;SSOR; x-forefront-antispam-report: SFV:SKI; SCL:-1; SFV:NSPM; SFS:(10009020)(376002)(396003)(39850400004)(39380400002)(366004)(346002)(13464003)(199004)(189003)(2950100002)(5660300001)(14454004)(99286004)(74316002)(81166006)(81156014)(54906003)(110136005)(316002)(93886005)(26005)(68736007)(3846002)(97736004)(2906002)(86362001)(59450400001)(55236004)(6116002)(105586002)(3280700002)(3660700001)(53376002)(2201001)(102836004)(53546011)(7696005)(8676002)(53936002)(478600001)(6246003)(55016002)(6306002)(33656002)(7736002)(9686003)(2501003)(305945005)(6436002)(8936002)(2900100001)(66066001)(8656006)(76176011)(229853002)(25786009)(72206003)(4326008)(5250100002)(5890100001)(966005)(106356001)(6506007); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR07MB3072; H:BY1PR0701MB1111.namprd07.prod.outlook.com; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; x-ms-office365-filtering-correlation-id: 77d951a7-6364-49c9-d4d1-08d5625891f3 x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(5600026)(4604075)(3008032)(2017052603307)(7153060)(7193020); SRVR:MWHPR07MB3072; x-ms-traffictypediagnostic: MWHPR07MB3072: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(20558992708506)(185117386973197)(228905959029699); x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(6040501)(2401047)(5005006)(8121501046)(3231023)(2400081)(944501161)(10201501046)(3002001)(93006095)(93001095)(6041288)(20161123562045)(20161123560045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(6072148)(201708071742011); SRVR:MWHPR07MB3072; BCL:0; PCL:0; RULEID:(100000803101)(100110400095); SRVR:MWHPR07MB3072; x-forefront-prvs: 05610E64EE received-spf: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: U9j9DoR1WXFjpANhdj91a/8io1+qalBvEInTPZb8/sKbaQTe6Yq7o3WNW6eLrDYIPPk+iCL4+xy8Y9e6k5Y3DQ== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-Network-Message-Id: 77d951a7-6364-49c9-d4d1-08d5625891f3 X-MS-Exchange-CrossTenant-originalarrivaltime: 23 Jan 2018 11:58:08.6394 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR07MB3072 Subject: Re: [dpdk-dev] [RFC v3 1/1] lib: add compressdev API X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Jan 2018 11:58:14 -0000 Hi Fiona > -----Original Message----- > From: Trahe, Fiona [mailto:fiona.trahe@intel.com] > Sent: 19 January 2018 17:30 > To: Verma, Shally ; dev@dpdk.org; > akhil.goyal@nxp.com > Cc: Challa, Mahipal ; Athreya, Narayana > Prasad ; De Lara Guarch, Pablo > ; Gupta, Ashish > ; Sahu, Sunila ; > Jain, Deepak K ; Hemant Agrawal > ; Roy Pledge ; Youri > Querry ; Ahmed Mansour > ; Trahe, Fiona > Subject: RE: [RFC v3 1/1] lib: add compressdev API >=20 > Hi Shally, >=20 > > -----Original Message----- > > From: Verma, Shally [mailto:Shally.Verma@cavium.com] > > Sent: Thursday, January 18, 2018 12:54 PM > > To: Trahe, Fiona ; dev@dpdk.org > > Cc: Challa, Mahipal ; Athreya, Narayana > Prasad > > ; De Lara Guarch, Pablo > ; > > Gupta, Ashish ; Sahu, Sunila > ; Jain, Deepak K > > ; Hemant Agrawal > ; Roy Pledge > > ; Youri Querry ; > Ahmed Mansour > > > > Subject: RE: [RFC v3 1/1] lib: add compressdev API > > > > Hi Fiona > > > > While revisiting this, we identified few questions and additions. Pleas= e see > them inline. > > > > > > > -----Original Message----- > > > From: Trahe, Fiona [mailto:fiona.trahe@intel.com] > > > Sent: 15 December 2017 23:19 > > > To: dev@dpdk.org; Verma, Shally > > > Cc: Challa, Mahipal ; Athreya, Narayana > > > Prasad ; > > > pablo.de.lara.guarch@intel.com; fiona.trahe@intel.com > > > Subject: [RFC v3 1/1] lib: add compressdev API > > > > > > Signed-off-by: Trahe, Fiona > > > --- > > > > //snip > > > > > + > > > +int > > > +rte_compressdev_queue_pair_setup(uint8_t dev_id, uint16_t > > > queue_pair_id, > > > + uint32_t max_inflight_ops, int socket_id) > > > > [Shally] Is max_inflights_ops different from nb_streams_per_qp in struc= t > rte_compressdev_info? > > I assume they both carry same purpose. If yes, then it will be better t= o use > single naming convention to > > avoid confusion. > [Fiona] No, I think they have different purposes. > max_inflight_ops should be used to configure the qp with the number of op= s > the application expects to be able to submit to the qp before it needs to= poll > for a response. It can be configured differently for each qp. In the QAT = case it > dictates the depth of the qp created, it may have different implications = on > other PMDs. > nb_sessions_per_qp and nb_streams_per_qp are limitations the devices > reports and are same for all qps on the device. QAT doesn't have those > limitations and so would report 0, however I assumed they may be necessar= y > for other devices. > This assumption is based on the patch submitted by NXP to cryptodev in Fe= b > 2017 > http://dpdk.org/ml/archives/dev/2017-March/060740.html > I also assume these are not necessarily the max number of sessions in ops= on > the qp at a given time, but the total number attached, i.e. if the device= has > this limitation then sessions must be attached to qps, and presumably > reserve some resources. Being attached doesn't imply there is an op on th= e > qp at that time using that session. So it's not to relating to the inflig= ht op > count, but to the number of sessions attached/detached to the qp. > Including Akhil on the To list, maybe NXP can confirm if these params are > needed. [Shally] Ok. Then let's wait for NXP to confirm on this requirement as curr= ently spec doesn't have any API to attach queue_pair_to_specific_session_or= _stream as cryptodev. But then how application could know limit on max_inflight_ops supported on = a qp? As it can pass any random number during qp_setup(). Do you believe we need to add a capability field in dev_info to indicate li= mit on max_inflight_ops? Thanks Shally >=20 >=20 > > Also, is it optional API? Like Is this a valid use case?: > > dev_configure() --> dev_start() --> qp_start() --> enqueue/dequeue() --= > > qp_stop() --> dev_stop() --> > > dev_close()? > [Fiona] I don't think it should be optional as some PMDs need to allocate > resources based on the setup data passed in on this API. >=20 > > //snip > > > > > + > > > +#define RTE_COMPRESSDEV_PMD_NAME_ARG > > > ("name") > > > +#define RTE_COMPRESSDEV_PMD_MAX_NB_QP_ARG > > > ("max_nb_queue_pairs") > > > +#define RTE_COMPRESSDEV_PMD_SOCKET_ID_ARG > ("socket_id") > > > + > > > > [Shally] Need to define argument macro for max_nb_session_per_qp and > max_nb_streams_per_qp as > > well > [Fiona] ok >=20 > > > + > > > +static const char * const compressdev_pmd_valid_params[] =3D { > > > + RTE_COMPRESSDEV_PMD_NAME_ARG, > > > + RTE_COMPRESSDEV_PMD_MAX_NB_QP_ARG, > > > + RTE_COMPRESSDEV_PMD_SOCKET_ID_ARG > > > +}; > > > > [Shally] Likewise, array need to be updated with other mentioned two > arguments > Fiona] ok >=20 >=20 > > > + > > > +/** > > > + * @internal > > > + * Initialisation parameters for comp devices > > > + */ > > > +struct rte_compressdev_pmd_init_params { > > > + char name[RTE_COMPRESSDEV_NAME_MAX_LEN]; > > > + size_t private_data_size; > > > + int socket_id; > > > + unsigned int max_nb_queue_pairs; > > > > [Shally] And this also need to be updated with max_nb_sessions_per_qp > and max_streams_per_qp > [Fiona] ok >=20 > > //snip > > > > Thanks > > Shally