diff options
Diffstat (limited to 'include/net/xfrm.h')
-rw-r--r-- | include/net/xfrm.h | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/include/net/xfrm.h b/include/net/xfrm.h index 248874ecf8df..7f1630630dcf 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h | |||
@@ -869,6 +869,23 @@ xfrm_state_addr_check(struct xfrm_state *x, | |||
869 | return 0; | 869 | return 0; |
870 | } | 870 | } |
871 | 871 | ||
872 | static __inline__ int | ||
873 | xfrm_state_addr_flow_check(struct xfrm_state *x, struct flowi *fl, | ||
874 | unsigned short family) | ||
875 | { | ||
876 | switch (family) { | ||
877 | case AF_INET: | ||
878 | return __xfrm4_state_addr_check(x, | ||
879 | (xfrm_address_t *)&fl->fl4_dst, | ||
880 | (xfrm_address_t *)&fl->fl4_src); | ||
881 | case AF_INET6: | ||
882 | return __xfrm6_state_addr_check(x, | ||
883 | (xfrm_address_t *)&fl->fl6_dst, | ||
884 | (xfrm_address_t *)&fl->fl6_src); | ||
885 | } | ||
886 | return 0; | ||
887 | } | ||
888 | |||
872 | static inline int xfrm_state_kern(struct xfrm_state *x) | 889 | static inline int xfrm_state_kern(struct xfrm_state *x) |
873 | { | 890 | { |
874 | return atomic_read(&x->tunnel_users); | 891 | return atomic_read(&x->tunnel_users); |
@@ -1014,7 +1031,7 @@ extern void xfrm_policy_flush(void); | |||
1014 | extern int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol); | 1031 | extern int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol); |
1015 | extern int xfrm_flush_bundles(void); | 1032 | extern int xfrm_flush_bundles(void); |
1016 | extern void xfrm_flush_all_bundles(void); | 1033 | extern void xfrm_flush_all_bundles(void); |
1017 | extern int xfrm_bundle_ok(struct xfrm_dst *xdst, struct flowi *fl, int family); | 1034 | extern int xfrm_bundle_ok(struct xfrm_dst *xdst, struct flowi *fl, int family, int strict); |
1018 | extern void xfrm_init_pmtu(struct dst_entry *dst); | 1035 | extern void xfrm_init_pmtu(struct dst_entry *dst); |
1019 | 1036 | ||
1020 | extern wait_queue_head_t km_waitq; | 1037 | extern wait_queue_head_t km_waitq; |