Commit e33f770426674a565a188042caf3f974f8b3722d
1 parent
e1ad2ab2cf
Exists in
master
and in
20 other branches
xfrm: Mark flowi arg to security_xfrm_state_pol_flow_match() const.
Signed-off-by: David S. Miller <davem@davemloft.net>
Showing 5 changed files with 9 additions and 7 deletions Side-by-side Diff
include/linux/security.h
... | ... | @@ -1623,7 +1623,7 @@ |
1623 | 1623 | int (*xfrm_policy_lookup) (struct xfrm_sec_ctx *ctx, u32 fl_secid, u8 dir); |
1624 | 1624 | int (*xfrm_state_pol_flow_match) (struct xfrm_state *x, |
1625 | 1625 | struct xfrm_policy *xp, |
1626 | - struct flowi *fl); | |
1626 | + const struct flowi *fl); | |
1627 | 1627 | int (*xfrm_decode_session) (struct sk_buff *skb, u32 *secid, int ckall); |
1628 | 1628 | #endif /* CONFIG_SECURITY_NETWORK_XFRM */ |
1629 | 1629 | |
... | ... | @@ -2761,7 +2761,8 @@ |
2761 | 2761 | void security_xfrm_state_free(struct xfrm_state *x); |
2762 | 2762 | int security_xfrm_policy_lookup(struct xfrm_sec_ctx *ctx, u32 fl_secid, u8 dir); |
2763 | 2763 | int security_xfrm_state_pol_flow_match(struct xfrm_state *x, |
2764 | - struct xfrm_policy *xp, struct flowi *fl); | |
2764 | + struct xfrm_policy *xp, | |
2765 | + const struct flowi *fl); | |
2765 | 2766 | int security_xfrm_decode_session(struct sk_buff *skb, u32 *secid); |
2766 | 2767 | void security_skb_classify_flow(struct sk_buff *skb, struct flowi *fl); |
2767 | 2768 | |
... | ... | @@ -2813,7 +2814,7 @@ |
2813 | 2814 | } |
2814 | 2815 | |
2815 | 2816 | static inline int security_xfrm_state_pol_flow_match(struct xfrm_state *x, |
2816 | - struct xfrm_policy *xp, struct flowi *fl) | |
2817 | + struct xfrm_policy *xp, const struct flowi *fl) | |
2817 | 2818 | { |
2818 | 2819 | return 1; |
2819 | 2820 | } |
security/capability.c
security/security.c
... | ... | @@ -1233,7 +1233,8 @@ |
1233 | 1233 | } |
1234 | 1234 | |
1235 | 1235 | int security_xfrm_state_pol_flow_match(struct xfrm_state *x, |
1236 | - struct xfrm_policy *xp, struct flowi *fl) | |
1236 | + struct xfrm_policy *xp, | |
1237 | + const struct flowi *fl) | |
1237 | 1238 | { |
1238 | 1239 | return security_ops->xfrm_state_pol_flow_match(x, xp, fl); |
1239 | 1240 | } |
security/selinux/include/xfrm.h
... | ... | @@ -19,7 +19,7 @@ |
19 | 19 | int selinux_xfrm_state_delete(struct xfrm_state *x); |
20 | 20 | int selinux_xfrm_policy_lookup(struct xfrm_sec_ctx *ctx, u32 fl_secid, u8 dir); |
21 | 21 | int selinux_xfrm_state_pol_flow_match(struct xfrm_state *x, |
22 | - struct xfrm_policy *xp, struct flowi *fl); | |
22 | + struct xfrm_policy *xp, const struct flowi *fl); | |
23 | 23 | |
24 | 24 | /* |
25 | 25 | * Extract the security blob from the sock (it's actually on the socket) |