#include <rte_ethdev.h>
#include <rte_malloc.h>
#include <rte_memcpy.h>
-#include <rte_dev.h>
+#include <rte_vdev.h>
#include <rte_kvargs.h>
#include <rte_spinlock.h>
goto error;
/* reserve an ethdev entry */
- eth_dev = rte_eth_dev_allocate(name, RTE_ETH_DEV_VIRTUAL);
+ eth_dev = rte_eth_dev_allocate(name);
if (eth_dev == NULL)
goto error;
return 0;
}
-static struct rte_driver pmd_null_drv = {
- .type = PMD_VDEV,
+static struct rte_vdev_driver pmd_null_drv = {
.init = rte_pmd_null_devinit,
.uninit = rte_pmd_null_devuninit,
};
-PMD_REGISTER_DRIVER(pmd_null_drv, eth_null);
-DRIVER_REGISTER_PARAM_STRING(eth_null,
+DRIVER_REGISTER_VDEV(net_null, pmd_null_drv);
+DRIVER_REGISTER_PARAM_STRING(net_null,
"size=<int> "
"copy=<int>");