18 #include <sys/queue.h> 22 struct rte_vdev_device {
23 TAILQ_ENTRY(rte_vdev_device) next;
31 #define RTE_DEV_TO_VDEV(ptr) \ 32 container_of(ptr, struct rte_vdev_device, device) 34 #define RTE_DEV_TO_VDEV_CONST(ptr) \ 35 container_of(ptr, const struct rte_vdev_device, device) 37 static inline const char *
38 rte_vdev_device_name(
const struct rte_vdev_device *dev)
40 if (dev && dev->device.name)
41 return dev->device.name;
45 static inline const char *
46 rte_vdev_device_args(
const struct rte_vdev_device *dev)
48 if (dev && dev->device.devargs)
49 return dev->device.devargs->args;
94 #define RTE_PMD_REGISTER_VDEV(nm, vdrv)\ 95 static const char *vdrvinit_ ## nm ## _alias;\ 96 RTE_INIT(vdrvinitfn_ ##vdrv)\ 98 (vdrv).driver.name = RTE_STR(nm);\ 99 (vdrv).driver.alias = vdrvinit_ ## nm ## _alias;\ 100 rte_vdev_register(&vdrv);\ 102 RTE_PMD_EXPORT_NAME(nm, __COUNTER__) 104 #define RTE_PMD_REGISTER_ALIAS(nm, alias)\ 105 static const char *vdrvinit_ ## nm ## _alias = RTE_STR(alias) 107 typedef void (*rte_vdev_scan_callback)(
void *user_arg);
int rte_vdev_uninit(const char *name)
int rte_vdev_init(const char *name, const char *args)
void rte_vdev_register(struct rte_vdev_driver *driver)
int rte_vdev_remove_custom_scan(rte_vdev_scan_callback callback, void *user_arg)
void rte_vdev_unregister(struct rte_vdev_driver *driver)
int rte_vdev_add_custom_scan(rte_vdev_scan_callback callback, void *user_arg)
int() rte_vdev_remove_t(struct rte_vdev_device *dev)
TAILQ_HEAD(vdev_driver_list, rte_vdev_driver)
int() rte_vdev_probe_t(struct rte_vdev_device *dev)