X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=app%2Ftest%2Fvirtual_pmd.c;h=02ac4851b0fb9c22cf5e267763a0532cfc00df47;hb=refs%2Ftags%2Fupstream%2F16.11.8;hp=b4bd2f27ccdffcc312e13e8bd681aaba02659668;hpb=97f17497d162afdb82c8704bf097f0fee3724b2e;p=deb_dpdk.git diff --git a/app/test/virtual_pmd.c b/app/test/virtual_pmd.c index b4bd2f27..02ac4851 100644 --- a/app/test/virtual_pmd.c +++ b/app/test/virtual_pmd.c @@ -241,6 +241,11 @@ static void virtual_ethdev_promiscuous_mode_disable(struct rte_eth_dev *dev __rte_unused) {} +static void +virtual_ethdev_mac_address_set(__rte_unused struct rte_eth_dev *dev, + __rte_unused struct ether_addr *addr) +{ +} static const struct eth_dev_ops virtual_ethdev_default_dev_ops = { .dev_configure = virtual_ethdev_configure_success, @@ -253,13 +258,13 @@ static const struct eth_dev_ops virtual_ethdev_default_dev_ops = { .rx_queue_release = virtual_ethdev_rx_queue_release, .tx_queue_release = virtual_ethdev_tx_queue_release, .link_update = virtual_ethdev_link_update_success, + .mac_addr_set = virtual_ethdev_mac_address_set, .stats_get = virtual_ethdev_stats_get, .stats_reset = virtual_ethdev_stats_reset, .promiscuous_enable = virtual_ethdev_promiscuous_mode_enable, .promiscuous_disable = virtual_ethdev_promiscuous_mode_disable }; - void virtual_ethdev_start_fn_set_success(uint8_t port_id, uint8_t success) { @@ -485,7 +490,7 @@ virtual_ethdev_simulate_link_status_interrupt(uint8_t port_id, vrtl_eth_dev->data->dev_link.link_status = link_status; - _rte_eth_dev_callback_process(vrtl_eth_dev, RTE_ETH_EVENT_INTR_LSC); + _rte_eth_dev_callback_process(vrtl_eth_dev, RTE_ETH_EVENT_INTR_LSC, NULL); } int @@ -581,12 +586,12 @@ virtual_ethdev_create(const char *name, struct ether_addr *mac_addr, goto err; /* reserve an ethdev entry */ - eth_dev = rte_eth_dev_allocate(name, RTE_ETH_DEV_PCI); + eth_dev = rte_eth_dev_allocate(name); if (eth_dev == NULL) goto err; - pci_dev->numa_node = socket_id; - pci_drv->name = virtual_ethdev_driver_name; + pci_dev->device.numa_node = socket_id; + pci_drv->driver.name = virtual_ethdev_driver_name; pci_drv->id_table = id_table; if (isr_support) @@ -626,7 +631,7 @@ virtual_ethdev_create(const char *name, struct ether_addr *mac_addr, eth_dev->dev_ops = &dev_private->dev_ops; eth_dev->pci_dev = pci_dev; - eth_dev->pci_dev->driver = ð_drv->pci_drv; + eth_dev->pci_dev->device.driver = ð_drv->pci_drv.driver; eth_dev->rx_pkt_burst = virtual_ethdev_rx_burst_success; eth_dev->tx_pkt_burst = virtual_ethdev_tx_burst_success;