]> git.baikalelectronics.ru Git - kernel.git/commit
cxgb4: fix EOTID leak when disabling TC-MQPRIO offload
authorRahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Wed, 29 Apr 2020 18:52:19 +0000 (00:22 +0530)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 May 2020 04:01:46 +0000 (21:01 -0700)
commit4a54098b48481f3824674541f60777a91f8d81f2
tree426d577afa15ae240a7d2c75a1652f81ffc78b04
parent6503327091c02041195da94886a146ec5ba0735f
cxgb4: fix EOTID leak when disabling TC-MQPRIO offload

Under heavy load, the EOTID termination FLOWC request fails to get
enqueued to the end of the Tx ring due to lack of credits. This
results in EOTID leak.

When disabling TC-MQPRIO offload, the link is already brought down
to cleanup EOTIDs. So, flush any pending enqueued skbs that can't be
sent outside the wire, to make room for FLOWC request. Also, move the
FLOWC descriptor consumption logic closer to when the FLOWC request is
actually posted to hardware.

Fixes: b589259108dc ("cxgb4: add FLOWC based QoS offload")
Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb4/sge.c