summaryrefslogtreecommitdiff
path: root/drivers/net/ring
diff options
context:
space:
mode:
authorJan Blunck <jblunck@infradead.org>2017-04-11 17:44:13 +0200
committerThomas Monjalon <thomas.monjalon@6wind.com>2017-04-14 15:41:50 +0200
commit5d2aa461cbcae1b5ede5cee0b0b3a1228c4afc59 (patch)
treecdbb28e8aafa97df84700f068c5bcc7578c8a328 /drivers/net/ring
parentdda987315ca27a8db7d7127b3634ae5227357ba2 (diff)
downloaddpdk-next-eventdev-5d2aa461cbcae1b5ede5cee0b0b3a1228c4afc59.zip
dpdk-next-eventdev-5d2aa461cbcae1b5ede5cee0b0b3a1228c4afc59.tar.gz
dpdk-next-eventdev-5d2aa461cbcae1b5ede5cee0b0b3a1228c4afc59.tar.xz
vdev: use generic vdev struct for probe and remove
This is a preparation to embed the generic rte_device into the rte_eth_dev also for virtual devices. Signed-off-by: Jan Blunck <jblunck@infradead.org> Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
Diffstat (limited to 'drivers/net/ring')
-rw-r--r--drivers/net/ring/rte_eth_ring.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/net/ring/rte_eth_ring.c b/drivers/net/ring/rte_eth_ring.c
index 77ef3a1..4bae895 100644
--- a/drivers/net/ring/rte_eth_ring.c
+++ b/drivers/net/ring/rte_eth_ring.c
@@ -502,12 +502,16 @@ out:
}
static int
-rte_pmd_ring_probe(const char *name, const char *params)
+rte_pmd_ring_probe(struct rte_vdev_device *dev)
{
+ const char *name, *params;
struct rte_kvargs *kvlist = NULL;
int ret = 0;
struct node_action_list *info = NULL;
+ name = rte_vdev_device_name(dev);
+ params = rte_vdev_device_args(dev);
+
RTE_LOG(INFO, PMD, "Initializing pmd_ring for %s\n", name);
if (params == NULL || params[0] == '\0') {
@@ -577,8 +581,9 @@ out_free:
}
static int
-rte_pmd_ring_remove(const char *name)
+rte_pmd_ring_remove(struct rte_vdev_device *dev)
{
+ const char *name = rte_vdev_device_name(dev);
struct rte_eth_dev *eth_dev = NULL;
struct pmd_internals *internals = NULL;
struct ring_queue *r = NULL;