From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 203D1388F; Tue, 20 Jun 2017 16:35:23 +0200 (CEST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 20 Jun 2017 07:35:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.39,364,1493708400"; d="scan'208";a="983074072" Received: from dwdohert-mobl1.ger.corp.intel.com (HELO [163.33.228.228]) ([163.33.228.228]) by orsmga003.jf.intel.com with ESMTP; 20 Jun 2017 07:35:08 -0700 To: Pablo de Lara , thomas@monjalon.net References: <1495639634-74846-1-git-send-email-pablo.de.lara.guarch@intel.com> <1495639634-74846-4-git-send-email-pablo.de.lara.guarch@intel.com> Cc: dev@dpdk.org, stable@dpdk.org From: Declan Doherty Message-ID: <003924ea-dca1-3a44-1067-3323894c7d69@intel.com> Date: Tue, 20 Jun 2017 15:35:07 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <1495639634-74846-4-git-send-email-pablo.de.lara.guarch@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 03/12] cryptodev: rename device retrieval argument 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, 20 Jun 2017 14:35:24 -0000 On 24/05/2017 4:27 PM, Pablo de Lara wrote: > rte_cryptodev_devices_get() function was parsing a crypto > device name as an argument, but the function actually > returns device identifiers of devices that share the > same crypto driver, so the argument should be driver name, instead. > > Fixes: 38227c0e3ad2 ("cryptodev: retrieve device info") > CC: stable@dpdk.org > > Signed-off-by: Pablo de Lara > --- > lib/librte_cryptodev/rte_cryptodev.c | 2 +- > lib/librte_cryptodev/rte_cryptodev.h | 7 ++++--- > 2 files changed, 5 insertions(+), 4 deletions(-) > > diff --git a/lib/librte_cryptodev/rte_cryptodev.c b/lib/librte_cryptodev/rte_cryptodev.c > index a5a5c36..6880661 100644 > --- a/lib/librte_cryptodev/rte_cryptodev.c > +++ b/lib/librte_cryptodev/rte_cryptodev.c > @@ -523,7 +523,7 @@ rte_cryptodev_count_devtype(enum rte_cryptodev_type type) > } > > uint8_t > -rte_cryptodev_devices_get(const char *dev_name, uint8_t *devices, > +rte_cryptodev_devices_get(const char *driver_name, uint8_t *devices, > uint8_t nb_devices) > { > uint8_t i, count = 0; Compilation breaks after this change, needs next patch to build > diff --git a/lib/librte_cryptodev/rte_cryptodev.h b/lib/librte_cryptodev/rte_cryptodev.h > index f307b3b..89093f6 100644 > --- a/lib/librte_cryptodev/rte_cryptodev.h > +++ b/lib/librte_cryptodev/rte_cryptodev.h > @@ -464,9 +464,10 @@ extern uint8_t > rte_cryptodev_count_devtype(enum rte_cryptodev_type type); > > /** > - * Get number and identifiers of attached crypto device. > + * Get number and identifiers of attached crypto devices that > + * use the same crypto driver. > * > - * @param dev_name device name. > + * @param driver_name driver name. > * @param devices output devices identifiers. > * @param nb_devices maximal number of devices. > * > @@ -474,7 +475,7 @@ rte_cryptodev_count_devtype(enum rte_cryptodev_type type); > * Returns number of attached crypto device. > */ > uint8_t > -rte_cryptodev_devices_get(const char *dev_name, uint8_t *devices, > +rte_cryptodev_devices_get(const char *driver_name, uint8_t *devices, > uint8_t nb_devices); > /* > * Return the NUMA socket to which a device is connected >