ICE_TX_CTX_EIPT_NONE == 0. There is a good chance that !(anything & 0) is always true :-).
While removing this part of the check is doable, let's keep a check that the descriptor does contain a outer ip type. Fixes: 2ed011776334 ("net/ice: fix outer UDP Tx checksum offload") Signed-off-by: David Marchand <david.march...@redhat.com> --- drivers/net/ice/ice_rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c index 13aabe97a5..efa189855e 100644 --- a/drivers/net/ice/ice_rxtx.c +++ b/drivers/net/ice/ice_rxtx.c @@ -2751,7 +2751,7 @@ ice_parse_tunneling_params(uint64_t ol_flags, * Calculate the tunneling UDP checksum. * Shall be set only if L4TUNT = 01b and EIPT is not zero */ - if (!(*cd_tunneling & ICE_TX_CTX_EIPT_NONE) && + if (!(*cd_tunneling & ICE_TXD_CTX_QW0_EIPT_M) && (*cd_tunneling & ICE_TXD_CTX_UDP_TUNNELING) && (ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM)) *cd_tunneling |= ICE_TXD_CTX_QW0_L4T_CS_M; -- 2.44.0