diff options
author | Yuval Atias <yuvala@mellanox.com> | 2014-05-14 12:15:10 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-05-14 15:40:32 -0400 |
commit | 2eacc23c422b4553030168f315cb49522fa1b1f6 (patch) | |
tree | 8733ae07b5752215afc6510a68f6ad7645297872 /drivers/net/ethernet/mellanox/mlx4/en_tx.c | |
parent | 3763e7ef17143f5e9ae044638e65d2b0c0305fcf (diff) | |
download | linux-2eacc23c422b4553030168f315cb49522fa1b1f6.tar.gz linux-2eacc23c422b4553030168f315cb49522fa1b1f6.tar.bz2 linux-2eacc23c422b4553030168f315cb49522fa1b1f6.zip |
net/mlx4_core: Enforce irq affinity changes immediatly
During heavy traffic, napi is constatntly polling the complition queue
and no interrupt is fired. Because of that, changes to irq affinity are
ignored until traffic is stopped and resumed.
By registering to the irq notifier mechanism, and forcing interrupt when
affinity is changed, irq affinity changes will be immediatly enforced.
Signed-off-by: Yuval Atias <yuvala@mellanox.com>
Signed-off-by: Amir Vadai <amirv@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx4/en_tx.c')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx4/en_tx.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_tx.c b/drivers/net/ethernet/mellanox/mlx4/en_tx.c index 89585c6311c3..cb964056d710 100644 --- a/drivers/net/ethernet/mellanox/mlx4/en_tx.c +++ b/drivers/net/ethernet/mellanox/mlx4/en_tx.c @@ -474,9 +474,15 @@ int mlx4_en_poll_tx_cq(struct napi_struct *napi, int budget) /* If we used up all the quota - we're probably not done yet... */ if (done < budget) { /* Done for now */ + cq->mcq.irq_affinity_change = false; napi_complete(napi); mlx4_en_arm_cq(priv, cq); return done; + } else if (unlikely(cq->mcq.irq_affinity_change)) { + cq->mcq.irq_affinity_change = false; + napi_complete(napi); + mlx4_en_arm_cq(priv, cq); + return 0; } return budget; } |