From mboxrd@z Thu Jan 1 00:00:00 1970 From: Shreyansh Jain Subject: Re: [PATCH v3 05/20] eal: introduce device class abstraction Date: Tue, 27 Mar 2018 14:08:31 +0530 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org To: Gaetan Rivet Return-path: Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-eopbgr20075.outbound.protection.outlook.com [40.107.2.75]) by dpdk.org (Postfix) with ESMTP id 689F82C12 for ; Tue, 27 Mar 2018 10:38:59 +0200 (CEST) In-Reply-To: Content-Language: en-US List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 3/27/2018 4:48 AM, Gaetan Rivet wrote: > Signed-off-by: Gaetan Rivet > --- > lib/librte_eal/bsdapp/eal/Makefile | 1 + > lib/librte_eal/common/Makefile | 2 +- > lib/librte_eal/common/eal_common_class.c | 62 +++++++++++++++ > lib/librte_eal/common/include/rte_class.h | 121 +++++++++++++++++++++++++++++ > lib/librte_eal/common/include/rte_common.h | 1 + > lib/librte_eal/linuxapp/eal/Makefile | 1 + > lib/librte_eal/rte_eal_version.map | 2 + > 7 files changed, 189 insertions(+), 1 deletion(-) > create mode 100644 lib/librte_eal/common/eal_common_class.c > create mode 100644 lib/librte_eal/common/include/rte_class.h > [...] > + > +/** > + * Class iterator to find a particular class. > + * > + * This function compares each registered class to find one that matches > + * the data passed as parameter. > + * > + * If the comparison function returns zero this function will stop iterating > + * over any more classes. To continue a search the class of a previous search > + * can be passed via the start parameter. > + * > + * @param start > + * Starting point for the iteration. > + * > + * @param cmp > + * Comparison function. > + * > + * @param data > + * Data to pass to comparison function. > + * > + * @return > + * A pointer to a rte_bus structure or NULL in case no class matches Trivial: ^^^^^^^^ Should be rte_class [...] - Shreyansh