Patch "nfp: fix esp-tx-csum-offload doesn't take effect" has been added to the 6.2-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    nfp: fix esp-tx-csum-offload doesn't take effect

to the 6.2-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     nfp-fix-esp-tx-csum-offload-doesn-t-take-effect.patch
and it can be found in the queue-6.2 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit c1bf299b63cc2744c3612c55abd5c88326e7c07f
Author: Huanhuan Wang <huanhuan.wang@xxxxxxxxxxxx>
Date:   Thu Mar 2 10:58:30 2023 +0100

    nfp: fix esp-tx-csum-offload doesn't take effect
    
    [ Upstream commit 1cf78d4c4144ffdbc2c9d505db482cb204bb480b ]
    
    When esp-tx-csum-offload is set to on, the protocol stack shouldn't
    calculate the IPsec offload packet's csum, but it does. Because the
    callback `.ndo_features_check` incorrectly masked NETIF_F_CSUM_MASK bit.
    
    Fixes: 57f273adbcd4 ("nfp: add framework to support ipsec offloading")
    Signed-off-by: Huanhuan Wang <huanhuan.wang@xxxxxxxxxxxx>
    Signed-off-by: Simon Horman <simon.horman@xxxxxxxxxxxx>
    Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
index 70d7484c82af4..1182fa48a3b54 100644
--- a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
+++ b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
@@ -38,6 +38,7 @@
 #include <net/tls.h>
 #include <net/vxlan.h>
 #include <net/xdp_sock_drv.h>
+#include <net/xfrm.h>
 
 #include "nfpcore/nfp_dev.h"
 #include "nfpcore/nfp_nsp.h"
@@ -1897,6 +1898,9 @@ nfp_net_features_check(struct sk_buff *skb, struct net_device *dev,
 			features &= ~NETIF_F_GSO_MASK;
 	}
 
+	if (xfrm_offload(skb))
+		return features;
+
 	/* VXLAN/GRE check */
 	switch (vlan_get_protocol(skb)) {
 	case htons(ETH_P_IP):



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux