[dpdk-dev] net/sfc: fix inner TCP/UDP checksum offload control

Message ID 1525953582-18202-1-git-send-email-arybchenko@solarflare.com (mailing list archive)
State Accepted, archived
Delegated to: Ferruh Yigit
Headers

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Andrew Rybchenko May 10, 2018, 11:59 a.m. UTC
  If application uses Tx offload API and sets ETH_TXQ_FLAGS_IGNORE flag,
it still should have inner TCP/UDP checksum offload enabled if it is
supported and TCP/UDP checksum offload is requested.

Fixes: c78d280e88ef ("net/sfc: convert to new Tx offload API")
Cc: stable@dpdk.org

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 drivers/net/sfc/sfc_tx.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
  

Comments

Ferruh Yigit May 10, 2018, 11:13 p.m. UTC | #1
On 5/10/2018 12:59 PM, Andrew Rybchenko wrote:
> If application uses Tx offload API and sets ETH_TXQ_FLAGS_IGNORE flag,
> it still should have inner TCP/UDP checksum offload enabled if it is
> supported and TCP/UDP checksum offload is requested.
> 
> Fixes: c78d280e88ef ("net/sfc: convert to new Tx offload API")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>

Applied to dpdk-next-net/master, thanks.
  

Patch

diff --git a/drivers/net/sfc/sfc_tx.c b/drivers/net/sfc/sfc_tx.c
index 579bfab7e..1bcc2c697 100644
--- a/drivers/net/sfc/sfc_tx.c
+++ b/drivers/net/sfc/sfc_tx.c
@@ -449,8 +449,7 @@  sfc_tx_qstart(struct sfc_adapter *sa, unsigned int sw_index)
 	    (txq->offloads & DEV_TX_OFFLOAD_UDP_CKSUM)) {
 		flags |= EFX_TXQ_CKSUM_TCPUDP;
 
-		if ((~txq->flags & ETH_TXQ_FLAGS_IGNORE) &&
-		    (offloads_supported & DEV_TX_OFFLOAD_OUTER_IPV4_CKSUM))
+		if (offloads_supported & DEV_TX_OFFLOAD_OUTER_IPV4_CKSUM)
 			flags |= EFX_TXQ_CKSUM_INNER_TCPUDP;
 	}