bus/fslmc: support check of dpbp presence
authorHemant Agrawal <hemant.agrawal@nxp.com>
Sat, 16 Sep 2017 10:52:26 +0000 (16:22 +0530)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 6 Oct 2017 01:24:17 +0000 (03:24 +0200)
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c
drivers/bus/fslmc/portal/dpaa2_hw_pvt.h
drivers/bus/fslmc/rte_bus_fslmc_version.map

index 1ddd280..7e96115 100644 (file)
@@ -129,6 +129,13 @@ void dpaa2_free_dpbp_dev(struct dpaa2_dpbp_dev *dpbp)
        }
 }
 
+int dpaa2_dpbp_supported(void)
+{
+       if (TAILQ_EMPTY(&dpbp_dev_list))
+               return -1;
+       return 0;
+}
+
 static struct rte_dpaa2_object rte_dpaa2_dpbp_obj = {
        .dev_type = DPAA2_BPOOL,
        .create = dpaa2_create_dpbp_device,
index bb52a15..8f39cfb 100644 (file)
@@ -366,6 +366,7 @@ void set_swp_active_dqs(uint16_t dpio_index, struct qbman_result *dqs)
 }
 struct dpaa2_dpbp_dev *dpaa2_alloc_dpbp_dev(void);
 void dpaa2_free_dpbp_dev(struct dpaa2_dpbp_dev *dpbp);
+int dpaa2_dpbp_supported(void);
 
 struct dpaa2_dpci_dev *rte_dpaa2_alloc_dpci_dev(void);
 void rte_dpaa2_free_dpci_dev(struct dpaa2_dpci_dev *dpci);
index 3cc7dad..7b25248 100644 (file)
@@ -83,6 +83,7 @@ DPDK_17.08 {
 DPDK_17.11 {
        global:
 
+       dpaa2_dpbp_supported;
        rte_dpaa2_dev_type;
 
 } DPDK_17.08;