@@ -37,7 +37,6 @@ struct seg6_action_desc {
int action;
unsigned long attrs;
int (*input)(struct sk_buff *skb, struct seg6_local_lwt *slwt);
- int static_headroom;
};
struct bpf_lwt_prog {
@@ -55,7 +54,6 @@ struct seg6_local_lwt {
int oif;
struct bpf_lwt_prog bpf;
- int headroom;
struct seg6_action_desc *desc;
};
@@ -603,7 +601,6 @@ static struct seg6_action_desc seg6_action_table[] = {
.action = SEG6_LOCAL_ACTION_END_B6_ENCAP,
.attrs = (1 << SEG6_LOCAL_SRH),
.input = input_action_end_b6_encap,
- .static_headroom = sizeof(struct ipv6hdr),
},
{
.action = SEG6_LOCAL_ACTION_END_BPF,
@@ -677,8 +674,6 @@ static int parse_nla_srh(struct nlattr **attrs, struct seg6_local_lwt *slwt)
if (!slwt->srh)
return -ENOMEM;
- slwt->headroom += len;
-
return 0;
}
@@ -952,7 +947,6 @@ static int parse_nla_action(struct nlattr **attrs, struct seg6_local_lwt *slwt)
return -EOPNOTSUPP;
slwt->desc = desc;
- slwt->headroom += desc->static_headroom;
for (i = 0; i < SEG6_LOCAL_MAX + 1; i++) {
if (desc->attrs & (1 << i)) {
@@ -1004,7 +998,6 @@ static int seg6_local_build_state(struct nlattr *nla, unsigned int family,
newts->type = LWTUNNEL_ENCAP_SEG6_LOCAL;
newts->flags = LWTUNNEL_STATE_INPUT_REDIRECT;
- newts->headroom = slwt->headroom;
*ts = newts;
The headroom value only need to be set on tunnels before Layer 3 like mpls. Remove it from seg6_local because it's in Layer 3. Signed-off-by: Alexander Aring <alex.aring@gmail.com> --- net/ipv6/seg6_local.c | 7 ------- 1 file changed, 7 deletions(-)