From mboxrd@z Thu Jan 1 00:00:00 1970 From: Santosh Shukla Subject: [PATCH v10 1/9] eal/pci: export match function Date: Fri, 6 Oct 2017 16:33:38 +0530 Message-ID: <20171006110346.13247-2-santosh.shukla@caviumnetworks.com> References: <20170920112356.17629-1-santosh.shukla@caviumnetworks.com> <20171006110346.13247-1-santosh.shukla@caviumnetworks.com> Mime-Version: 1.0 Content-Type: text/plain Cc: thomas@monjalon.net, jerin.jacob@caviumnetworks.com, hemant.agrawal@nxp.com, aconole@redhat.com, stephen@networkplumber.org, anatoly.burakov@intel.com, gaetan.rivet@6wind.com, shreyansh.jain@nxp.com, bruce.richardson@intel.com, sergio.gonzalez.monroy@intel.com, maxime.coquelin@redhat.com, Santosh Shukla To: olivier.matz@6wind.com, dev@dpdk.org Return-path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0073.outbound.protection.outlook.com [104.47.38.73]) by dpdk.org (Postfix) with ESMTP id 750EE1B2A5 for ; Fri, 6 Oct 2017 13:04:19 +0200 (CEST) In-Reply-To: <20171006110346.13247-1-santosh.shukla@caviumnetworks.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Export rte_pci_match() function as it needed in the followup patch. Signed-off-by: Santosh Shukla Signed-off-by: Jerin Jacob Acked-by: Maxime Coquelin Reviewed-by: Anatoly Burakov Tested-by: Hemant Agrawal --- lib/librte_eal/bsdapp/eal/rte_eal_version.map | 7 +++++++ lib/librte_eal/common/eal_common_pci.c | 10 +--------- lib/librte_eal/common/include/rte_pci.h | 15 +++++++++++++++ lib/librte_eal/linuxapp/eal/rte_eal_version.map | 7 +++++++ 4 files changed, 30 insertions(+), 9 deletions(-) diff --git a/lib/librte_eal/bsdapp/eal/rte_eal_version.map b/lib/librte_eal/bsdapp/eal/rte_eal_version.map index 47a09ea7f..cfbf8fbd0 100644 --- a/lib/librte_eal/bsdapp/eal/rte_eal_version.map +++ b/lib/librte_eal/bsdapp/eal/rte_eal_version.map @@ -238,3 +238,10 @@ EXPERIMENTAL { rte_service_start_with_defaults; } DPDK_17.08; + +DPDK_17.11 { + global: + + rte_pci_match; + +} DPDK_17.08; diff --git a/lib/librte_eal/common/eal_common_pci.c b/lib/librte_eal/common/eal_common_pci.c index 52fd38cdd..3b7d0a0ee 100644 --- a/lib/librte_eal/common/eal_common_pci.c +++ b/lib/librte_eal/common/eal_common_pci.c @@ -150,16 +150,8 @@ pci_unmap_resource(void *requested_addr, size_t size) /* * Match the PCI Driver and Device using the ID Table - * - * @param pci_drv - * PCI driver from which ID table would be extracted - * @param pci_dev - * PCI device to match against the driver - * @return - * 1 for successful match - * 0 for unsuccessful match */ -static int +int rte_pci_match(const struct rte_pci_driver *pci_drv, const struct rte_pci_device *pci_dev) { diff --git a/lib/librte_eal/common/include/rte_pci.h b/lib/librte_eal/common/include/rte_pci.h index 8b123391c..eab84c7a4 100644 --- a/lib/librte_eal/common/include/rte_pci.h +++ b/lib/librte_eal/common/include/rte_pci.h @@ -366,6 +366,21 @@ int rte_pci_scan(void); int rte_pci_probe(void); +/* + * Match the PCI Driver and Device using the ID Table + * + * @param pci_drv + * PCI driver from which ID table would be extracted + * @param pci_dev + * PCI device to match against the driver + * @return + * 1 for successful match + * 0 for unsuccessful match + */ +int +rte_pci_match(const struct rte_pci_driver *pci_drv, + const struct rte_pci_device *pci_dev); + /** * Map the PCI device resources in user space virtual memory address * diff --git a/lib/librte_eal/linuxapp/eal/rte_eal_version.map b/lib/librte_eal/linuxapp/eal/rte_eal_version.map index 8c08b8d1e..287cc75cd 100644 --- a/lib/librte_eal/linuxapp/eal/rte_eal_version.map +++ b/lib/librte_eal/linuxapp/eal/rte_eal_version.map @@ -243,3 +243,10 @@ EXPERIMENTAL { rte_service_start_with_defaults; } DPDK_17.08; + +DPDK_17.11 { + global: + + rte_pci_match; + +} DPDK_17.08; -- 2.14.1