rte_free(txq);
}
- /* Free MAC address table */
- rte_free(dev->data->mac_addrs);
- dev->data->mac_addrs = NULL;
-
octeontx_port_close(nic);
dev->tx_pkt_burst = NULL;
data->promiscuous = 0;
data->all_multicast = 0;
data->scattered_rx = 0;
+ data->dev_flags |= RTE_ETH_DEV_CLOSE_REMOVE;
/* Get maximum number of supported MAC entries */
max_entries = octeontx_bgx_port_mac_entries_get(nic->port_id);
for (i = 0; i < OCTEONTX_VDEV_DEFAULT_MAX_NR_PORT; i++) {
sprintf(octtx_name, "eth_octeontx_%d", i);
- /* reserve an ethdev entry */
eth_dev = rte_eth_dev_allocated(octtx_name);
if (eth_dev == NULL)
- return -ENODEV;
+ continue; /* port already released */
if (rte_eal_process_type() != RTE_PROC_PRIMARY) {
rte_eth_dev_release_port(eth_dev);
nic = octeontx_pmd_priv(eth_dev);
rte_event_dev_stop(nic->evdev);
PMD_INIT_LOG(INFO, "Closing octeontx device %s", octtx_name);
-
+ octeontx_dev_close(eth_dev);
rte_eth_dev_release_port(eth_dev);
- rte_event_dev_close(nic->evdev);
}
if (rte_eal_process_type() != RTE_PROC_PRIMARY)