summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIdo Shamay <idos@mellanox.com>2014-10-27 12:37:45 +0300
committerDavid S. Miller <davem@davemloft.net>2014-10-29 00:18:01 +0300
commitf4a36751584bbdfcfd6f3f232e0fe899763434a4 (patch)
tree716865a871b9bdded17c7405c148a5e6542a81bc
parentc2a3d4b4cac1a9ad0547b0807e118cb34885dbd5 (diff)
downloadlinux-f4a36751584bbdfcfd6f3f232e0fe899763434a4.tar.xz
net/mlx4_en: Call napi_synchronize on stop_port
This is instead of calling the actual implementation of napi_synchronize, for better encapsulation. Signed-off-by: Ido Shamay <idos@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/mellanox/mlx4/en_netdev.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
index a23aa309e2f0..0e77cb27d7d7 100644
--- a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
+++ b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
@@ -1843,8 +1843,7 @@ void mlx4_en_stop_port(struct net_device *dev, int detach)
}
local_bh_enable();
- while (test_bit(NAPI_STATE_SCHED, &cq->napi.state))
- msleep(1);
+ napi_synchronize(&cq->napi);
mlx4_en_deactivate_rx_ring(priv, priv->rx_ring[i]);
mlx4_en_deactivate_cq(priv, cq);