diff options
author | Florian Westphal <fw@strlen.de> | 2018-12-18 17:15:24 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-12-19 11:21:37 -0800 |
commit | 26912e3756d0a13b188142d1ba0ab279cd3b657a (patch) | |
tree | 04001073156fcb35d51f4e232f550363b335b175 /include | |
parent | 56d1ac3260dadfc66c81ef2689bd1a09b05731a2 (diff) |
xfrm: use secpath_exist where applicable
Will reduce noise when skb->sp is removed later in this series.
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/net/xfrm.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/net/xfrm.h b/include/net/xfrm.h index af723448c972..31220edcce95 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h @@ -1185,7 +1185,7 @@ static inline int __xfrm_policy_check2(struct sock *sk, int dir, if (sk && sk->sk_policy[XFRM_POLICY_IN]) return __xfrm_policy_check(sk, ndir, skb, family); - return (!net->xfrm.policy_count[dir] && !skb->sp) || + return (!net->xfrm.policy_count[dir] && !secpath_exists(skb)) || (skb_dst(skb)->flags & DST_NOPOLICY) || __xfrm_policy_check(sk, ndir, skb, family); } |