static int iavf_dev_configure(struct rte_eth_dev *dev);
static int iavf_dev_start(struct rte_eth_dev *dev);
-static void iavf_dev_stop(struct rte_eth_dev *dev);
+static int iavf_dev_stop(struct rte_eth_dev *dev);
static int iavf_dev_close(struct rte_eth_dev *dev);
static int iavf_dev_reset(struct rte_eth_dev *dev);
static int iavf_dev_info_get(struct rte_eth_dev *dev,
return -1;
}
-static void
+static int
iavf_dev_stop(struct rte_eth_dev *dev)
{
struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(dev->data->dev_private);
PMD_INIT_FUNC_TRACE();
if (adapter->stopped == 1)
- return;
+ return 0;
iavf_stop_queues(dev);
adapter->stopped = 1;
dev->data->dev_started = 0;
+
+ return 0;
}
static int
return 0;
}
rte_eth_copy_pci_info(eth_dev, pci_dev);
+ eth_dev->data->dev_flags |= RTE_ETH_DEV_AUTOFILL_QUEUE_XSTATS;
hw->vendor_id = pci_dev->id.vendor_id;
hw->device_id = pci_dev->id.device_id;
struct iavf_adapter *adapter =
IAVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private);
struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(dev->data->dev_private);
+ int ret;
if (rte_eal_process_type() != RTE_PROC_PRIMARY)
return 0;
- iavf_dev_stop(dev);
+ ret = iavf_dev_stop(dev);
+
iavf_flow_flush(dev, NULL);
iavf_flow_uninit(adapter);
vf->vf_reset = false;
- return 0;
+ return ret;
}
static int