]> git.droids-corp.org - dpdk.git/blobdiff - lib/librte_ether/rte_ethdev.c
ethdev: use device handle to detach
[dpdk.git] / lib / librte_ether / rte_ethdev.c
index 71a576cedb064f860eba8404aba6305a57bdd98a..798af41e6cb9292f01a484a180628a9755482ad6 100644 (file)
@@ -440,7 +440,8 @@ rte_eth_dev_detach(uint8_t port_id, char *name)
 
        snprintf(name, sizeof(rte_eth_devices[port_id].data->name),
                 "%s", rte_eth_devices[port_id].data->name);
-       ret = rte_eal_dev_detach(name);
+
+       ret = rte_eal_dev_detach(rte_eth_devices[port_id].device);
        if (ret < 0)
                goto err;