net/netvsc: fix calculation of checksums based on mbuf flag
authorLong Li <longli@microsoft.com>
Thu, 24 Mar 2022 17:46:08 +0000 (10:46 -0700)
committerFerruh Yigit <ferruh.yigit@xilinx.com>
Tue, 26 Apr 2022 21:46:58 +0000 (23:46 +0200)
commit559a1f2eeaaddccc83e1668a8ee375c34699e48b
tree7bc673cb5a699794ca607b063979c83025bf3111
parentb14e8a57b9fe8ccd65b46b023201f554c6bb4e96
net/netvsc: fix calculation of checksums based on mbuf flag

The netvsc should use RTE_MBUF_F_TX_L4_MASK and check the masked value
to decide the correct way to calculate checksums.

Not checking for RTE_MBUF_F_TX_L4_MASK results in incorrect RNDIS
packets sent to VSP and incorrect checksums calculated by the VSP.

Fixes: 4e9c73e96e ("net/netvsc: add Hyper-V network device")
Cc: stable@dpdk.org
Signed-off-by: Long Li <longli@microsoft.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@xilinx.com>
drivers/net/netvsc/hn_rxtx.c