diff options
author | Nicolas Dichtel <nicolas.dichtel@6wind.com> | 2014-03-06 12:24:29 -0500 |
---|---|---|
committer | Steffen Klassert <steffen.klassert@secunet.com> | 2014-03-07 02:12:37 -0500 |
commit | 870a2df4ca026817eb87bb2f9daaa60a93fd051a (patch) | |
tree | 4a52243174074e0fc5b1a838ae5cf3e31f688190 | |
parent | e50287be7c007a10e6e2e3332e52466faf4b6a04 (diff) |
xfrm: rename struct xfrm_filter
iproute2 already defines a structure with that name, let's use another one to
avoid any conflict.
CC: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
-rw-r--r-- | include/net/xfrm.h | 4 | ||||
-rw-r--r-- | include/uapi/linux/xfrm.h | 4 | ||||
-rw-r--r-- | net/key/af_key.c | 2 | ||||
-rw-r--r-- | net/xfrm/xfrm_state.c | 4 | ||||
-rw-r--r-- | net/xfrm/xfrm_user.c | 8 |
5 files changed, 11 insertions, 11 deletions
diff --git a/include/net/xfrm.h b/include/net/xfrm.h index 8b925288a8bc..ce3d96f752fd 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h | |||
@@ -121,7 +121,7 @@ struct xfrm_state_walk { | |||
121 | u8 dying; | 121 | u8 dying; |
122 | u8 proto; | 122 | u8 proto; |
123 | u32 seq; | 123 | u32 seq; |
124 | struct xfrm_filter *filter; | 124 | struct xfrm_address_filter *filter; |
125 | }; | 125 | }; |
126 | 126 | ||
127 | /* Full description of state of transformer. */ | 127 | /* Full description of state of transformer. */ |
@@ -1423,7 +1423,7 @@ static inline void xfrm_sysctl_fini(struct net *net) | |||
1423 | #endif | 1423 | #endif |
1424 | 1424 | ||
1425 | void xfrm_state_walk_init(struct xfrm_state_walk *walk, u8 proto, | 1425 | void xfrm_state_walk_init(struct xfrm_state_walk *walk, u8 proto, |
1426 | struct xfrm_filter *filter); | 1426 | struct xfrm_address_filter *filter); |
1427 | int xfrm_state_walk(struct net *net, struct xfrm_state_walk *walk, | 1427 | int xfrm_state_walk(struct net *net, struct xfrm_state_walk *walk, |
1428 | int (*func)(struct xfrm_state *, int, void*), void *); | 1428 | int (*func)(struct xfrm_state *, int, void*), void *); |
1429 | void xfrm_state_walk_done(struct xfrm_state_walk *walk, struct net *net); | 1429 | void xfrm_state_walk_done(struct xfrm_state_walk *walk, struct net *net); |
diff --git a/include/uapi/linux/xfrm.h b/include/uapi/linux/xfrm.h index 6550c679584f..25e5dd916ba4 100644 --- a/include/uapi/linux/xfrm.h +++ b/include/uapi/linux/xfrm.h | |||
@@ -299,7 +299,7 @@ enum xfrm_attr_type_t { | |||
299 | XFRMA_REPLAY_ESN_VAL, /* struct xfrm_replay_esn */ | 299 | XFRMA_REPLAY_ESN_VAL, /* struct xfrm_replay_esn */ |
300 | XFRMA_SA_EXTRA_FLAGS, /* __u32 */ | 300 | XFRMA_SA_EXTRA_FLAGS, /* __u32 */ |
301 | XFRMA_PROTO, /* __u8 */ | 301 | XFRMA_PROTO, /* __u8 */ |
302 | XFRMA_FILTER, /* struct xfrm_filter */ | 302 | XFRMA_ADDRESS_FILTER, /* struct xfrm_address_filter */ |
303 | __XFRMA_MAX | 303 | __XFRMA_MAX |
304 | 304 | ||
305 | #define XFRMA_MAX (__XFRMA_MAX - 1) | 305 | #define XFRMA_MAX (__XFRMA_MAX - 1) |
@@ -476,7 +476,7 @@ struct xfrm_user_mapping { | |||
476 | __be16 new_sport; | 476 | __be16 new_sport; |
477 | }; | 477 | }; |
478 | 478 | ||
479 | struct xfrm_filter { | 479 | struct xfrm_address_filter { |
480 | xfrm_address_t saddr; | 480 | xfrm_address_t saddr; |
481 | xfrm_address_t daddr; | 481 | xfrm_address_t daddr; |
482 | __u16 family; | 482 | __u16 family; |
diff --git a/net/key/af_key.c b/net/key/af_key.c index a50d979b5926..12651b42aad8 100644 --- a/net/key/af_key.c +++ b/net/key/af_key.c | |||
@@ -1799,7 +1799,7 @@ static void pfkey_dump_sa_done(struct pfkey_sock *pfk) | |||
1799 | static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) | 1799 | static int pfkey_dump(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) |
1800 | { | 1800 | { |
1801 | u8 proto; | 1801 | u8 proto; |
1802 | struct xfrm_filter *filter = NULL; | 1802 | struct xfrm_address_filter *filter = NULL; |
1803 | struct pfkey_sock *pfk = pfkey_sk(sk); | 1803 | struct pfkey_sock *pfk = pfkey_sk(sk); |
1804 | 1804 | ||
1805 | if (pfk->dump.dump != NULL) | 1805 | if (pfk->dump.dump != NULL) |
diff --git a/net/xfrm/xfrm_state.c b/net/xfrm/xfrm_state.c index 5339c26bb0cf..cee850c76165 100644 --- a/net/xfrm/xfrm_state.c +++ b/net/xfrm/xfrm_state.c | |||
@@ -1598,7 +1598,7 @@ unlock: | |||
1598 | EXPORT_SYMBOL(xfrm_alloc_spi); | 1598 | EXPORT_SYMBOL(xfrm_alloc_spi); |
1599 | 1599 | ||
1600 | static bool __xfrm_state_filter_match(struct xfrm_state *x, | 1600 | static bool __xfrm_state_filter_match(struct xfrm_state *x, |
1601 | struct xfrm_filter *filter) | 1601 | struct xfrm_address_filter *filter) |
1602 | { | 1602 | { |
1603 | if (filter) { | 1603 | if (filter) { |
1604 | if ((filter->family == AF_INET || | 1604 | if ((filter->family == AF_INET || |
@@ -1657,7 +1657,7 @@ out: | |||
1657 | EXPORT_SYMBOL(xfrm_state_walk); | 1657 | EXPORT_SYMBOL(xfrm_state_walk); |
1658 | 1658 | ||
1659 | void xfrm_state_walk_init(struct xfrm_state_walk *walk, u8 proto, | 1659 | void xfrm_state_walk_init(struct xfrm_state_walk *walk, u8 proto, |
1660 | struct xfrm_filter *filter) | 1660 | struct xfrm_address_filter *filter) |
1661 | { | 1661 | { |
1662 | INIT_LIST_HEAD(&walk->all); | 1662 | INIT_LIST_HEAD(&walk->all); |
1663 | walk->proto = proto; | 1663 | walk->proto = proto; |
diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c index 023e5e7ea4c6..903725b8cc70 100644 --- a/net/xfrm/xfrm_user.c +++ b/net/xfrm/xfrm_user.c | |||
@@ -904,7 +904,7 @@ static int xfrm_dump_sa(struct sk_buff *skb, struct netlink_callback *cb) | |||
904 | 904 | ||
905 | if (!cb->args[0]) { | 905 | if (!cb->args[0]) { |
906 | struct nlattr *attrs[XFRMA_MAX+1]; | 906 | struct nlattr *attrs[XFRMA_MAX+1]; |
907 | struct xfrm_filter *filter = NULL; | 907 | struct xfrm_address_filter *filter = NULL; |
908 | u8 proto = 0; | 908 | u8 proto = 0; |
909 | int err; | 909 | int err; |
910 | 910 | ||
@@ -915,12 +915,12 @@ static int xfrm_dump_sa(struct sk_buff *skb, struct netlink_callback *cb) | |||
915 | if (err < 0) | 915 | if (err < 0) |
916 | return err; | 916 | return err; |
917 | 917 | ||
918 | if (attrs[XFRMA_FILTER]) { | 918 | if (attrs[XFRMA_ADDRESS_FILTER]) { |
919 | filter = kmalloc(sizeof(*filter), GFP_KERNEL); | 919 | filter = kmalloc(sizeof(*filter), GFP_KERNEL); |
920 | if (filter == NULL) | 920 | if (filter == NULL) |
921 | return -ENOMEM; | 921 | return -ENOMEM; |
922 | 922 | ||
923 | memcpy(filter, nla_data(attrs[XFRMA_FILTER]), | 923 | memcpy(filter, nla_data(attrs[XFRMA_ADDRESS_FILTER]), |
924 | sizeof(*filter)); | 924 | sizeof(*filter)); |
925 | } | 925 | } |
926 | 926 | ||
@@ -2334,7 +2334,7 @@ static const struct nla_policy xfrma_policy[XFRMA_MAX+1] = { | |||
2334 | [XFRMA_REPLAY_ESN_VAL] = { .len = sizeof(struct xfrm_replay_state_esn) }, | 2334 | [XFRMA_REPLAY_ESN_VAL] = { .len = sizeof(struct xfrm_replay_state_esn) }, |
2335 | [XFRMA_SA_EXTRA_FLAGS] = { .type = NLA_U32 }, | 2335 | [XFRMA_SA_EXTRA_FLAGS] = { .type = NLA_U32 }, |
2336 | [XFRMA_PROTO] = { .type = NLA_U8 }, | 2336 | [XFRMA_PROTO] = { .type = NLA_U8 }, |
2337 | [XFRMA_FILTER] = { .len = sizeof(struct xfrm_filter) }, | 2337 | [XFRMA_ADDRESS_FILTER] = { .len = sizeof(struct xfrm_address_filter) }, |
2338 | }; | 2338 | }; |
2339 | 2339 | ||
2340 | static const struct xfrm_link { | 2340 | static const struct xfrm_link { |