]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
net: thunderx: Fix transmit queue timeout issue
authorSunil Goutham <sgoutham@cavium.com>
Thu, 1 Dec 2016 12:54:28 +0000 (18:24 +0530)
committerDavid S. Miller <davem@davemloft.net>
Fri, 2 Dec 2016 18:32:59 +0000 (13:32 -0500)
commitbd3ad7d3a14b07aeeb4f92abc757672719e2a0eb
tree401add62a6c03cc480f2e4addba361eafe87abff
parent9aac3c18790cb3510810fafc7ba115e31d49f3bf
net: thunderx: Fix transmit queue timeout issue

Transmit queue timeout issue is seen in two cases
- Due to a race condition btw setting stop_queue at xmit()
  and checking for stopped_queue in NAPI poll routine, at times
  transmission from a SQ comes to a halt. This is fixed
  by using barriers and also added a check for SQ free descriptors,
  incase SQ is stopped and there are only CQE_RX i.e no CQE_TX.
- Contrary to an assumption, a HW errata where HW doesn't stop transmission
  even though there are not enough CQEs available for a CQE_TX is
  not fixed in T88 pass 2.x. This results in a Qset error with
  'CQ_WR_FULL' stalling transmission. This is fixed by adjusting
  RXQ's  RED levels for CQ level such that there is always enough
  space left for CQE_TXs.

Signed-off-by: Sunil Goutham <sgoutham@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/cavium/thunder/nicvf_main.c
drivers/net/ethernet/cavium/thunder/nicvf_queues.c
drivers/net/ethernet/cavium/thunder/nicvf_queues.h