diff options
author | Alexey Dobriyan <adobriyan@gmail.com> | 2005-09-23 02:45:24 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2005-09-23 02:45:24 -0400 |
commit | 67497205b12e3cb408259cc09b50c3a9d12cd935 (patch) | |
tree | b06cc4b76736ca7df03717f30ff57cab8848ab2a /net | |
parent | 0ae5d253adcc467b1c52b512bbca9419eb438409 (diff) |
[NETFILTER] Fix sparse endian warnings in pptp helper
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Harald Welte <laforge@netfilter.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/ipv4/netfilter/ip_conntrack_helper_pptp.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/net/ipv4/netfilter/ip_conntrack_helper_pptp.c b/net/ipv4/netfilter/ip_conntrack_helper_pptp.c index 117587978700..8236ee0fb090 100644 --- a/net/ipv4/netfilter/ip_conntrack_helper_pptp.c +++ b/net/ipv4/netfilter/ip_conntrack_helper_pptp.c | |||
@@ -223,8 +223,8 @@ static void pptp_destroy_siblings(struct ip_conntrack *ct) | |||
223 | static inline int | 223 | static inline int |
224 | exp_gre(struct ip_conntrack *master, | 224 | exp_gre(struct ip_conntrack *master, |
225 | u_int32_t seq, | 225 | u_int32_t seq, |
226 | u_int16_t callid, | 226 | __be16 callid, |
227 | u_int16_t peer_callid) | 227 | __be16 peer_callid) |
228 | { | 228 | { |
229 | struct ip_conntrack_tuple inv_tuple; | 229 | struct ip_conntrack_tuple inv_tuple; |
230 | struct ip_conntrack_tuple exp_tuples[] = { | 230 | struct ip_conntrack_tuple exp_tuples[] = { |
@@ -263,7 +263,7 @@ exp_gre(struct ip_conntrack *master, | |||
263 | exp_orig->mask.src.ip = 0xffffffff; | 263 | exp_orig->mask.src.ip = 0xffffffff; |
264 | exp_orig->mask.src.u.all = 0; | 264 | exp_orig->mask.src.u.all = 0; |
265 | exp_orig->mask.dst.u.all = 0; | 265 | exp_orig->mask.dst.u.all = 0; |
266 | exp_orig->mask.dst.u.gre.key = 0xffff; | 266 | exp_orig->mask.dst.u.gre.key = htons(0xffff); |
267 | exp_orig->mask.dst.ip = 0xffffffff; | 267 | exp_orig->mask.dst.ip = 0xffffffff; |
268 | exp_orig->mask.dst.protonum = 0xff; | 268 | exp_orig->mask.dst.protonum = 0xff; |
269 | 269 | ||
@@ -340,7 +340,8 @@ pptp_inbound_pkt(struct sk_buff **pskb, | |||
340 | unsigned int reqlen; | 340 | unsigned int reqlen; |
341 | union pptp_ctrl_union _pptpReq, *pptpReq; | 341 | union pptp_ctrl_union _pptpReq, *pptpReq; |
342 | struct ip_ct_pptp_master *info = &ct->help.ct_pptp_info; | 342 | struct ip_ct_pptp_master *info = &ct->help.ct_pptp_info; |
343 | u_int16_t msg, *cid, *pcid; | 343 | u_int16_t msg; |
344 | __be16 *cid, *pcid; | ||
344 | u_int32_t seq; | 345 | u_int32_t seq; |
345 | 346 | ||
346 | ctlh = skb_header_pointer(*pskb, nexthdr_off, sizeof(_ctlh), &_ctlh); | 347 | ctlh = skb_header_pointer(*pskb, nexthdr_off, sizeof(_ctlh), &_ctlh); |
@@ -551,7 +552,8 @@ pptp_outbound_pkt(struct sk_buff **pskb, | |||
551 | unsigned int reqlen; | 552 | unsigned int reqlen; |
552 | union pptp_ctrl_union _pptpReq, *pptpReq; | 553 | union pptp_ctrl_union _pptpReq, *pptpReq; |
553 | struct ip_ct_pptp_master *info = &ct->help.ct_pptp_info; | 554 | struct ip_ct_pptp_master *info = &ct->help.ct_pptp_info; |
554 | u_int16_t msg, *cid, *pcid; | 555 | u_int16_t msg; |
556 | __be16 *cid, *pcid; | ||
555 | 557 | ||
556 | ctlh = skb_header_pointer(*pskb, nexthdr_off, sizeof(_ctlh), &_ctlh); | 558 | ctlh = skb_header_pointer(*pskb, nexthdr_off, sizeof(_ctlh), &_ctlh); |
557 | if (!ctlh) | 559 | if (!ctlh) |
@@ -755,7 +757,7 @@ static struct ip_conntrack_helper pptp = { | |||
755 | } | 757 | } |
756 | }, | 758 | }, |
757 | .mask = { .src = { .ip = 0, | 759 | .mask = { .src = { .ip = 0, |
758 | .u = { .tcp = { .port = 0xffff } } | 760 | .u = { .tcp = { .port = __constant_htons(0xffff) } } |
759 | }, | 761 | }, |
760 | .dst = { .ip = 0, | 762 | .dst = { .ip = 0, |
761 | .u = { .all = 0 }, | 763 | .u = { .all = 0 }, |