From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on0074.outbound.protection.outlook.com [104.47.36.74]) by dpdk.org (Postfix) with ESMTP id 6A4524C7B for ; Mon, 14 May 2018 10:16:51 +0200 (CEST) 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=ZB2SQSrdIYV2XD2cPARibKHxqsj1HpQbbr5xu/hCaeA=; b=bHr2nNKqowBUYG7Ika+nAgFMydn8avc/DbDmD+WIMAHTnuXK17OkY7BVBeEnpmjexcC+h+sjr3N+zWcrC38Ldmb1jPzHM2jW0/PIswt6ap2S0Q5rJJSNm6sEiUlh1mTfBRun13ie1bqYtT49YW6plrNzceQQsEmH+SHAy79XTus= Received: from CY4PR0701MB3634.namprd07.prod.outlook.com (52.132.101.164) by CY4PR0701MB3793.namprd07.prod.outlook.com (52.132.102.149) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.755.16; Mon, 14 May 2018 08:16:48 +0000 Received: from CY4PR0701MB3634.namprd07.prod.outlook.com ([fe80::b0a9:2be9:bfdf:fc0a]) by CY4PR0701MB3634.namprd07.prod.outlook.com ([fe80::b0a9:2be9:bfdf:fc0a%13]) with mapi id 15.20.0755.018; Mon, 14 May 2018 08:16:47 +0000 From: "Verma, Shally" To: "De Lara Guarch, Pablo" , "dev@dpdk.org" CC: "Trahe, Fiona" , "ahmed.mansour@nxp.com" , "Gupta, Ashish" , "Gupta, Ashish" , "Sahu, Sunila" Thread-Topic: [PATCH v6 02/14] compressdev: add queue pair management Thread-Index: AQHT3isC5cf9BOid/UmSWBgovfMrsqQu9HrQgAADgYCAAADPwA== Date: Mon, 14 May 2018 08:16:47 +0000 Message-ID: References: <1517595924-25963-1-git-send-email-fiona.trahe@intel.com> <20180427132407.13385-1-pablo.de.lara.guarch@intel.com> <20180427132407.13385-3-pablo.de.lara.guarch@intel.com> In-Reply-To: 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; CY4PR0701MB3793; 7:cHcpRp0qBbKb8MOxJXlRP4xm9d3+3L/Rh6DvzLMQLaQNlkGIKlI8m8UcedzKjXUIgeUMdgSgy2ef4l5euaifAwhVHYlxX4knvD56kcN0xOlyycbvTUNluSMy3kykmtNAuxZi5/HxE/u6DBjxnKY88GHbe2zqtuYq6dLQX4eLd9FjKkR2o/WIcNjdL249X1rTvtKz/tcnKYNjd5w8z/3p8FodElHK7a5QAzgApodlokqoQtlxQ430PuQRKOFBHkMW x-ms-exchange-antispam-srfa-diagnostics: SOS;SOR; x-forefront-antispam-report: SFV:SKI; SCL:-1; SFV:NSPM; SFS:(10009020)(39380400002)(396003)(39860400002)(346002)(366004)(376002)(189003)(13464003)(199004)(305945005)(86362001)(59450400001)(55236004)(76176011)(7696005)(97736004)(8656006)(2900100001)(4326008)(2501003)(5250100002)(93886005)(55016002)(478600001)(8936002)(53546011)(25786009)(26005)(186003)(7736002)(99286004)(6506007)(8676002)(81156014)(81166006)(102836004)(14454004)(74316002)(72206003)(486006)(446003)(3660700001)(106356001)(66066001)(6436002)(54906003)(11346002)(2906002)(33656002)(476003)(6246003)(3280700002)(9686003)(6116002)(110136005)(5660300001)(68736007)(229853002)(316002)(53936002)(107886003)(105586002)(3846002); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR0701MB3793; H:CY4PR0701MB3634.namprd07.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:CY4PR0701MB3793; x-ms-traffictypediagnostic: CY4PR0701MB3793: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(185117386973197)(228905959029699); x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3231254)(944501410)(52105095)(93006095)(93001095)(3002001)(10201501046)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(20161123562045)(20161123564045)(20161123560045)(6072148)(201708071742011); SRVR:CY4PR0701MB3793; BCL:0; PCL:0; RULEID:; SRVR:CY4PR0701MB3793; x-forefront-prvs: 067270ECAF received-spf: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: f30uqh7tsXeDkQeZbCCkyDKQka7GG2VPdGBfPl56xnuQBkwbLaHf8vk/7AtuLTY3UbOMTqBlCI3SA7p7bDSIR023oSUZ16nWRD6Nzj1rz7d4U5aU/Jwl+yrTwxfE2He/mzT8n7A95NZBVvCNn5ueiZ5xmFdTQjqiKUz6PXQrTT4hbX8nkMTkZXkcNGt1gQN2 spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: cb3d4b9e-0aea-4f73-04ad-08d5b97309d3 X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-Network-Message-Id: cb3d4b9e-0aea-4f73-04ad-08d5b97309d3 X-MS-Exchange-CrossTenant-originalarrivaltime: 14 May 2018 08:16:47.9526 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR0701MB3793 Subject: Re: [dpdk-dev] [PATCH v6 02/14] compressdev: add queue pair management 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: Mon, 14 May 2018 08:16:51 -0000 >-----Original Message----- >From: De Lara Guarch, Pablo [mailto:pablo.de.lara.guarch@intel.com] >Sent: 14 May 2018 13:34 >To: Verma, Shally ; dev@dpdk.org >Cc: Trahe, Fiona ; ahmed.mansour@nxp.com; Gupta, As= hish ; Gupta, Ashish >; Sahu, Sunila >Subject: RE: [PATCH v6 02/14] compressdev: add queue pair management > >Hi Shally, > >> -----Original Message----- >> From: Verma, Shally [mailto:Shally.Verma@cavium.com] >> Sent: Monday, May 14, 2018 8:54 AM >> To: De Lara Guarch, Pablo ; dev@dpdk.org >> Cc: Trahe, Fiona ; ahmed.mansour@nxp.com; Gupta, >> Ashish ; Gupta, Ashish >> ; Sahu, Sunila >> Subject: RE: [PATCH v6 02/14] compressdev: add queue pair management >> >> HI Pablo >> >> >-----Original Message----- >> >From: Pablo de Lara [mailto:pablo.de.lara.guarch@intel.com] >> >Sent: 27 April 2018 18:54 >> >To: dev@dpdk.org >> >Cc: fiona.trahe@intel.com; Verma, Shally ; >> >ahmed.mansour@nxp.com; Gupta, Ashish ; Pablo >> >de Lara ; Verma, Shally >> >; Gupta, Ashish >> >Subject: [PATCH v6 02/14] compressdev: add queue pair management >> > >> >From: Fiona Trahe >> > >> >Add functions to manage device queue pairs. >> > >> >Signed-off-by: Fiona Trahe >> >Signed-off-by: Pablo de Lara >> >Signed-off-by: Shally Verma >> >Signed-off-by: Ashish Gupta >> >--- >> > lib/librte_compressdev/rte_compressdev.c | 178 >> ++++++++++++++++++++- >> > lib/librte_compressdev/rte_compressdev.h | 45 ++++++ >> > lib/librte_compressdev/rte_compressdev_internal.h | 5 + >> > lib/librte_compressdev/rte_compressdev_pmd.h | 47 ++++++ >> > lib/librte_compressdev/rte_compressdev_version.map | 2 + >> > 5 files changed, 276 insertions(+), 1 deletion(-) >> > >> >diff --git a/lib/librte_compressdev/rte_compressdev.c >> >b/lib/librte_compressdev/rte_compressdev.c >> >index 751517c3d..6667528b5 100644 >> >--- a/lib/librte_compressdev/rte_compressdev.c >> >+++ b/lib/librte_compressdev/rte_compressdev.c >> >@@ -227,10 +227,136 @@ rte_compressdev_pmd_release_device(struct >> rte_compressdev *compressdev) >> > return 0; >> > } >> > >> >+uint16_t __rte_experimental >> >+rte_compressdev_queue_pair_count(uint8_t dev_id) { >> >+ struct rte_compressdev *dev; >> >+ >> >+ dev =3D &rte_comp_devices[dev_id]; >> >+ return dev->data->nb_queue_pairs; >> >+} >> >+ >> >+static int >> >+rte_compressdev_queue_pairs_config(struct rte_compressdev *dev, >> >+ uint16_t nb_qpairs, int socket_id) >> >+{ >> >+ struct rte_compressdev_info dev_info; >> >+ void **qp; >> >+ unsigned int i; >> >+ >> >+ if ((dev =3D=3D NULL) || (nb_qpairs < 1)) { >> >+ COMPRESSDEV_LOG(ERR, "invalid param: dev %p, nb_queues >> %u", >> >+ dev, nb_qpairs); >> [Shally] shouldn't nb_qpairs < 0 as nb_qpairs =3D 0 a valid input which= imply >> number of supported qp is implementation defined and thus unlimited. > >You mean maximum number of queues. This is number of queues to configure, >which should be at least 1. App can call dev_configure with max as returned by dev_info_get(), in case = this value is 0 i.e. implementation defined, then app may choose to leave this value to 0 and configure device with its = default setup. App, in any case, will call for qp_setup()=20 to configure as many qp as it want. Isn't it so? =20 > >Thanks, >Pablo > >> >> Thanks >> Shally >> >> //snip