[dpdk-dev] [PATCH v2 08/11] vdev: implement unplug bus operation
Gaetan Rivet
gaetan.rivet at 6wind.com
Wed May 31 15:17:53 CEST 2017
From: Jan Blunck <jblunck at infradead.org>
Signed-off-by: Jan Blunck <jblunck at infradead.org>
Signed-off-by: Gaetan Rivet <gaetan.rivet at 6wind.com>
---
lib/librte_eal/common/eal_common_vdev.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/lib/librte_eal/common/eal_common_vdev.c b/lib/librte_eal/common/eal_common_vdev.c
index 813955e..67c6fff 100644
--- a/lib/librte_eal/common/eal_common_vdev.c
+++ b/lib/librte_eal/common/eal_common_vdev.c
@@ -356,11 +356,18 @@ vdev_plug(struct rte_devargs *da)
return rte_vdev_init(da->virt.drv_name, da->args);
}
+static int
+vdev_unplug(struct rte_devargs *da)
+{
+ return rte_vdev_uninit(da->virt.drv_name);
+}
+
static struct rte_bus rte_vdev_bus = {
.scan = vdev_scan,
.probe = vdev_probe,
.find_device = vdev_find_device,
.plug = vdev_plug,
+ .unplug = vdev_unplug,
};
RTE_INIT(rte_vdev_bus_register);
--
2.1.4
More information about the dev
mailing list