summaryrefslogtreecommitdiff
path: root/net/ipv6/esp6_offload.c
diff options
context:
space:
mode:
authorFlorian Westphal <fw@strlen.de>2018-12-18 19:15:20 +0300
committerDavid S. Miller <davem@davemloft.net>2018-12-19 22:21:37 +0300
commit2294be0f11e22b6197d025e5d3ab42888879ec4e (patch)
treef4e97bbe3475fa69f3100520f6d98f2d711ff852 /net/ipv6/esp6_offload.c
parent7af8f4ca314a592e2ba49cb5ea1de1325974998e (diff)
downloadlinux-2294be0f11e22b6197d025e5d3ab42888879ec4e.tar.xz
net: use skb_sec_path helper in more places
skb_sec_path gains 'const' qualifier to avoid xt_policy.c: 'skb_sec_path' discards 'const' qualifier from pointer target type same reasoning as previous conversions: Won't need to touch these spots anymore when skb->sp is removed. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/esp6_offload.c')
-rw-r--r--net/ipv6/esp6_offload.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/ipv6/esp6_offload.c b/net/ipv6/esp6_offload.c
index 01a97f5dfa4e..d46b4eb645c2 100644
--- a/net/ipv6/esp6_offload.c
+++ b/net/ipv6/esp6_offload.c
@@ -142,6 +142,7 @@ static struct sk_buff *esp6_gso_segment(struct sk_buff *skb,
struct crypto_aead *aead;
netdev_features_t esp_features = features;
struct xfrm_offload *xo = xfrm_offload(skb);
+ struct sec_path *sp;
if (!xo)
return ERR_PTR(-EINVAL);
@@ -149,7 +150,8 @@ static struct sk_buff *esp6_gso_segment(struct sk_buff *skb,
if (!(skb_shinfo(skb)->gso_type & SKB_GSO_ESP))
return ERR_PTR(-EINVAL);
- x = skb->sp->xvec[skb->sp->len - 1];
+ sp = skb_sec_path(skb);
+ x = sp->xvec[sp->len - 1];
aead = x->data;
esph = ip_esp_hdr(skb);