* @return
* - nothing
*/
-static void
+static int
lio_dev_close(struct rte_eth_dev *eth_dev)
{
struct lio_device *lio_dev = LIO_DEV(eth_dev);
+ if (rte_eal_process_type() != RTE_PROC_PRIMARY)
+ return 0;
+
lio_dev_info(lio_dev, "closing port %d\n", eth_dev->data->port_id);
if (lio_dev->intf_open)
/* Reset ioq regs */
lio_dev->fn_list.setup_device_regs(lio_dev);
- if (lio_dev->pci_dev->kdrv == RTE_KDRV_IGB_UIO) {
+ if (lio_dev->pci_dev->kdrv == RTE_PCI_KDRV_IGB_UIO) {
cn23xx_vf_ask_pf_to_do_flr(lio_dev);
rte_delay_ms(LIO_PCI_FLR_WAIT);
}
/* Delete all queues */
lio_dev_clear_queues(eth_dev);
+
+ return 0;
}
/**
goto error;
/* Request and wait for device reset. */
- if (pdev->kdrv == RTE_KDRV_IGB_UIO) {
+ if (pdev->kdrv == RTE_PCI_KDRV_IGB_UIO) {
cn23xx_vf_ask_pf_to_do_flr(lio_dev);
/* FLR wait time doubled as a precaution. */
rte_delay_ms(LIO_PCI_FLR_WAIT * 2);