]> git.droids-corp.org - dpdk.git/blobdiff - drivers/net/dpaa2/dpaa2_ethdev.c
bus/fslmc: set the dpaa2 device name
[dpdk.git] / drivers / net / dpaa2 / dpaa2_ethdev.c
index c19f7261d2b0dc87ddb3eda95d7aa3a4a9b579f5..9666d9d4c598145ed6617e42a5b73b7e35fe5a36 100644 (file)
@@ -1255,6 +1255,7 @@ dpaa2_flow_ctrl_set(struct rte_eth_dev *dev, struct rte_eth_fc_conf *fc_conf)
                 */
                cfg.options |= DPNI_LINK_OPT_PAUSE;
                cfg.options &= ~DPNI_LINK_OPT_ASYM_PAUSE;
+               break;
        case RTE_FC_TX_PAUSE:
                /* Enable RX flow control
                 * OPT_PAUSE not set;
@@ -1530,13 +1531,9 @@ rte_dpaa2_probe(struct rte_dpaa2_driver *dpaa2_drv,
                struct rte_dpaa2_device *dpaa2_dev)
 {
        struct rte_eth_dev *eth_dev;
-       char ethdev_name[RTE_ETH_NAME_MAX_LEN];
-
        int diag;
 
-       sprintf(ethdev_name, "dpni-%d", dpaa2_dev->object_id);
-
-       eth_dev = rte_eth_dev_allocate(ethdev_name);
+       eth_dev = rte_eth_dev_allocate(dpaa2_dev->device.name);
        if (eth_dev == NULL)
                return -ENOMEM;