From 7a004c64033f45ae01ad66bc4e5ecd162b181e4a Mon Sep 17 00:00:00 2001 From: Christian Hopps Date: Mon, 7 Aug 2023 16:11:34 -0400 Subject: [PATCH] iptfs: xfrm: generic IPTFS functionality --- net/ipv4/esp4_offload.c | 5 +++++ net/ipv6/esp6_offload.c | 5 +++++ net/xfrm/xfrm_device.c | 1 + 3 files changed, 11 insertions(+) diff --git a/net/ipv4/esp4_offload.c b/net/ipv4/esp4_offload.c index 3969fa805679cd..d04ba13288c232 100644 --- a/net/ipv4/esp4_offload.c +++ b/net/ipv4/esp4_offload.c @@ -184,6 +184,11 @@ static struct sk_buff *xfrm4_outer_mode_gso_segment(struct xfrm_state *x, return xfrm4_transport_gso_segment(x, skb, features); case XFRM_MODE_BEET: return xfrm4_beet_gso_segment(x, skb, features); +#if 0 + case XFRM_MODE_IPTFS: + /* XXX chopps: writeme */ + return xfrm4_iptfs_gso_segment(x, skb, features); +#endif } return ERR_PTR(-EOPNOTSUPP); diff --git a/net/ipv6/esp6_offload.c b/net/ipv6/esp6_offload.c index 75c02992c520f9..abd7283c817ec5 100644 --- a/net/ipv6/esp6_offload.c +++ b/net/ipv6/esp6_offload.c @@ -222,6 +222,11 @@ static struct sk_buff *xfrm6_outer_mode_gso_segment(struct xfrm_state *x, return xfrm6_transport_gso_segment(x, skb, features); case XFRM_MODE_BEET: return xfrm6_beet_gso_segment(x, skb, features); +#if 0 + case XFRM_MODE_IPTFS: + /* XXX chopps: writeme */ + return xfrm6_iptfs_gso_segment(x, skb, features); +#endif } return ERR_PTR(-EOPNOTSUPP); diff --git a/net/xfrm/xfrm_device.c b/net/xfrm/xfrm_device.c index a8f70fc262cd54..68727792830a1e 100644 --- a/net/xfrm/xfrm_device.c +++ b/net/xfrm/xfrm_device.c @@ -68,6 +68,7 @@ static void __xfrm_mode_beet_prep(struct xfrm_state *x, struct sk_buff *skb, static void xfrm_outer_mode_prep(struct xfrm_state *x, struct sk_buff *skb) { switch (x->outer_mode.encap) { + case XFRM_MODE_IPTFS: case XFRM_MODE_TUNNEL: if (x->outer_mode.family == AF_INET) return __xfrm_mode_tunnel_prep(x, skb,