diff options
Diffstat (limited to 'include/net/xfrm.h')
-rw-r--r-- | include/net/xfrm.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/include/net/xfrm.h b/include/net/xfrm.h index aa860add570b..8f8bd82606bf 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h | |||
@@ -1142,9 +1142,9 @@ xfrm_address_t *xfrm_flowi_daddr(const struct flowi *fl, unsigned short family) | |||
1142 | { | 1142 | { |
1143 | switch (family){ | 1143 | switch (family){ |
1144 | case AF_INET: | 1144 | case AF_INET: |
1145 | return (xfrm_address_t *)&fl->fl4_dst; | 1145 | return (xfrm_address_t *)&fl->u.ip4.daddr; |
1146 | case AF_INET6: | 1146 | case AF_INET6: |
1147 | return (xfrm_address_t *)&fl->fl6_dst; | 1147 | return (xfrm_address_t *)&fl->u.ip6.daddr; |
1148 | } | 1148 | } |
1149 | return NULL; | 1149 | return NULL; |
1150 | } | 1150 | } |
@@ -1154,9 +1154,9 @@ xfrm_address_t *xfrm_flowi_saddr(const struct flowi *fl, unsigned short family) | |||
1154 | { | 1154 | { |
1155 | switch (family){ | 1155 | switch (family){ |
1156 | case AF_INET: | 1156 | case AF_INET: |
1157 | return (xfrm_address_t *)&fl->fl4_src; | 1157 | return (xfrm_address_t *)&fl->u.ip4.saddr; |
1158 | case AF_INET6: | 1158 | case AF_INET6: |
1159 | return (xfrm_address_t *)&fl->fl6_src; | 1159 | return (xfrm_address_t *)&fl->u.ip6.saddr; |
1160 | } | 1160 | } |
1161 | return NULL; | 1161 | return NULL; |
1162 | } | 1162 | } |
@@ -1168,12 +1168,12 @@ void xfrm_flowi_addr_get(const struct flowi *fl, | |||
1168 | { | 1168 | { |
1169 | switch(family) { | 1169 | switch(family) { |
1170 | case AF_INET: | 1170 | case AF_INET: |
1171 | memcpy(&saddr->a4, &fl->fl4_src, sizeof(saddr->a4)); | 1171 | memcpy(&saddr->a4, &fl->u.ip4.saddr, sizeof(saddr->a4)); |
1172 | memcpy(&daddr->a4, &fl->fl4_dst, sizeof(daddr->a4)); | 1172 | memcpy(&daddr->a4, &fl->u.ip4.daddr, sizeof(daddr->a4)); |
1173 | break; | 1173 | break; |
1174 | case AF_INET6: | 1174 | case AF_INET6: |
1175 | ipv6_addr_copy((struct in6_addr *)&saddr->a6, &fl->fl6_src); | 1175 | ipv6_addr_copy((struct in6_addr *)&saddr->a6, &fl->u.ip6.saddr); |
1176 | ipv6_addr_copy((struct in6_addr *)&daddr->a6, &fl->fl6_dst); | 1176 | ipv6_addr_copy((struct in6_addr *)&daddr->a6, &fl->u.ip6.daddr); |
1177 | break; | 1177 | break; |
1178 | } | 1178 | } |
1179 | } | 1179 | } |
@@ -1221,12 +1221,12 @@ xfrm_state_addr_flow_check(const struct xfrm_state *x, const struct flowi *fl, | |||
1221 | switch (family) { | 1221 | switch (family) { |
1222 | case AF_INET: | 1222 | case AF_INET: |
1223 | return __xfrm4_state_addr_check(x, | 1223 | return __xfrm4_state_addr_check(x, |
1224 | (const xfrm_address_t *)&fl->fl4_dst, | 1224 | (const xfrm_address_t *)&fl->u.ip4.daddr, |
1225 | (const xfrm_address_t *)&fl->fl4_src); | 1225 | (const xfrm_address_t *)&fl->u.ip4.saddr); |
1226 | case AF_INET6: | 1226 | case AF_INET6: |
1227 | return __xfrm6_state_addr_check(x, | 1227 | return __xfrm6_state_addr_check(x, |
1228 | (const xfrm_address_t *)&fl->fl6_dst, | 1228 | (const xfrm_address_t *)&fl->u.ip6.daddr, |
1229 | (const xfrm_address_t *)&fl->fl6_src); | 1229 | (const xfrm_address_t *)&fl->u.ip6.saddr); |
1230 | } | 1230 | } |
1231 | return 0; | 1231 | return 0; |
1232 | } | 1232 | } |