detach a TUNTAP device. */
| 2564 | /* detach a TUNTAP device. |
| 2565 | */ |
| 2566 | static int |
| 2567 | rte_pmd_tap_remove(struct rte_vdev_device *dev) |
| 2568 | { |
| 2569 | struct rte_eth_dev *eth_dev = NULL; |
| 2570 | |
| 2571 | /* find the ethdev entry */ |
| 2572 | eth_dev = rte_eth_dev_allocated(rte_vdev_device_name(dev)); |
| 2573 | if (!eth_dev) |
| 2574 | return 0; |
| 2575 | |
| 2576 | tap_dev_close(eth_dev); |
| 2577 | rte_eth_dev_release_port(eth_dev); |
| 2578 | |
| 2579 | return 0; |
| 2580 | } |
| 2581 | |
| 2582 | static struct rte_vdev_driver pmd_tun_drv = { |
| 2583 | .probe = rte_pmd_tun_probe, |
nothing calls this directly
no test coverage detected