git: c7d13682a1ad - main - lagg: do not advertize support for ipsec offload

From: Konstantin Belousov <kib_at_FreeBSD.org>
Date: Tue, 17 Dec 2024 21:50:00 UTC
The branch main has been updated by kib:

URL: https://cgit.FreeBSD.org/src/commit/?id=c7d13682a1ad0e8f35d59989d64546c74da80eed

commit c7d13682a1ad0e8f35d59989d64546c74da80eed
Author:     Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2024-12-16 12:38:39 +0000
Commit:     Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2024-12-17 21:49:31 +0000

    lagg: do not advertize support for ipsec offload
    
    It is not implemented, and most likely cannot be, in a robust manner.
    
    Reviewed by:    Ariel Ehrenberg <aehrenberg@nvidia.com>, slavash
    Sponsored by:   NVidia networking
---
 sys/net/if_lagg.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/sys/net/if_lagg.c b/sys/net/if_lagg.c
index 988f23fc029c..9bc42cb8cbe6 100644
--- a/sys/net/if_lagg.c
+++ b/sys/net/if_lagg.c
@@ -692,6 +692,7 @@ lagg_capabilities(struct lagg_softc *sc)
 			ena2 &= lp->lp_ifp->if_capenable2;
 		}
 	} while (pena != ena || pena2 != ena2);
+	ena2 &= ~IFCAP2_BIT(IFCAP2_IPSEC_OFFLOAD);
 
 	/* Get other capabilities from the lagg ports */
 	cap = cap2 = ~0;
@@ -703,6 +704,7 @@ lagg_capabilities(struct lagg_softc *sc)
 		hwa &= lp->lp_ifp->if_hwassist;
 		if_hw_tsomax_common(lp->lp_ifp, &hw_tsomax);
 	}
+	cap2 &= ~IFCAP2_BIT(IFCAP2_IPSEC_OFFLOAD);
 	if (CK_SLIST_FIRST(&sc->sc_ports) == NULL)
 		cap = cap2 = hwa = 0;