]> git.baikalelectronics.ru Git - kernel.git/commit
net: mvpp2: do not call txq_done from the Tx path when Tx irqs are used
authorAntoine Tenart <antoine.tenart@free-electrons.com>
Mon, 23 Oct 2017 13:24:31 +0000 (15:24 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 24 Oct 2017 09:34:10 +0000 (18:34 +0900)
commit38958b2938d5536568d334fce2918f552174ef15
treeb3c0c88736e2f73dde398930d2418c1c704a1c69
parent386932caac35eecfb49fa0c4109325100c731c70
net: mvpp2: do not call txq_done from the Tx path when Tx irqs are used

When Tx IRQs are used, txq_bufs_free() can be called from both the Tx
path and from NAPI poll(). This led to CPU stalls as if these two tasks
(Tx and Poll) are scheduled on two CPUs at the same time, DMA unmapping
operations are done on the same txq buffers.

This patch adds a check not to call txq_done() from the Tx path if Tx
interrupts are used as it does not make sense to do so.

Fixes: 7dc6fd1e9e19 ("net: mvpp2: replace TX coalescing interrupts with hrtimer")
Signed-off-by: Antoine Tenart <antoine.tenart@free-electrons.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvpp2.c