net/tap: move link down before close

Fixes: f457b472b1f2 ("net/tap: add link up and down operations")

Signed-off-by: Keith Wiles <keith.wiles@intel.com>
Acked-by: Pascal Mazon <pascal.mazon@6wind.com>
This commit is contained in:
Keith Wiles 2017-02-06 13:40:37 -06:00 committed by Ferruh Yigit
parent 6157fd377c
commit 89a5bef09a

View File

@ -353,10 +353,11 @@ tap_dev_stop(struct rte_eth_dev *dev)
int i;
struct pmd_internals *internals = dev->data->dev_private;
tap_link_set_down(dev);
for (i = 0; i < internals->nb_queues; i++)
if (internals->rxq[i].fd != -1)
close(internals->rxq[i].fd);
tap_link_set_down(dev);
}
static int