diff options
author | Patrick McHardy <kaber@trash.net> | 2008-07-21 13:03:49 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-07-21 13:11:02 -0400 |
commit | 5547cd0ae8b46db9a084505239294eed9b8c8e2d (patch) | |
tree | 0ce92a2050c5b6bd8dfe50f6942fbd79da9cbc32 /net | |
parent | c71529e42ce39c167dc53430cb8f3d5634af77df (diff) |
netfilter: nf_conntrack_sctp: fix sparse warnings
Introduced by a258860e (netfilter: ctnetlink: add full support for SCTP to ctnetlink):
net/netfilter/nf_conntrack_proto_sctp.c:483:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:483:2: warning: incorrect type in argument 1 (different base types)
net/netfilter/nf_conntrack_proto_sctp.c:483:2: expected unsigned int [unsigned] [usertype] x
net/netfilter/nf_conntrack_proto_sctp.c:483:2: got restricted unsigned int const <noident>
net/netfilter/nf_conntrack_proto_sctp.c:483:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:483:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:483:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:483:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:487:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:487:2: warning: incorrect type in argument 1 (different base types)
net/netfilter/nf_conntrack_proto_sctp.c:487:2: expected unsigned int [unsigned] [usertype] x
net/netfilter/nf_conntrack_proto_sctp.c:487:2: got restricted unsigned int const <noident>
net/netfilter/nf_conntrack_proto_sctp.c:487:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:487:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:487:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:487:2: warning: cast from restricted type
net/netfilter/nf_conntrack_proto_sctp.c:532:42: warning: incorrect type in assignment (different base types)
net/netfilter/nf_conntrack_proto_sctp.c:532:42: expected restricted unsigned int <noident>
net/netfilter/nf_conntrack_proto_sctp.c:532:42: got unsigned int
net/netfilter/nf_conntrack_proto_sctp.c:534:39: warning: incorrect type in assignment (different base types)
net/netfilter/nf_conntrack_proto_sctp.c:534:39: expected restricted unsigned int <noident>
net/netfilter/nf_conntrack_proto_sctp.c:534:39: got unsigned int
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/netfilter/nf_conntrack_proto_sctp.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/netfilter/nf_conntrack_proto_sctp.c b/net/netfilter/nf_conntrack_proto_sctp.c index 41183a4d2d62..30aa5b94a771 100644 --- a/net/netfilter/nf_conntrack_proto_sctp.c +++ b/net/netfilter/nf_conntrack_proto_sctp.c | |||
@@ -482,11 +482,11 @@ static int sctp_to_nlattr(struct sk_buff *skb, struct nlattr *nla, | |||
482 | 482 | ||
483 | NLA_PUT_BE32(skb, | 483 | NLA_PUT_BE32(skb, |
484 | CTA_PROTOINFO_SCTP_VTAG_ORIGINAL, | 484 | CTA_PROTOINFO_SCTP_VTAG_ORIGINAL, |
485 | htonl(ct->proto.sctp.vtag[IP_CT_DIR_ORIGINAL])); | 485 | ct->proto.sctp.vtag[IP_CT_DIR_ORIGINAL]); |
486 | 486 | ||
487 | NLA_PUT_BE32(skb, | 487 | NLA_PUT_BE32(skb, |
488 | CTA_PROTOINFO_SCTP_VTAG_REPLY, | 488 | CTA_PROTOINFO_SCTP_VTAG_REPLY, |
489 | htonl(ct->proto.sctp.vtag[IP_CT_DIR_REPLY])); | 489 | ct->proto.sctp.vtag[IP_CT_DIR_REPLY]); |
490 | 490 | ||
491 | read_unlock_bh(&sctp_lock); | 491 | read_unlock_bh(&sctp_lock); |
492 | 492 | ||
@@ -530,9 +530,9 @@ static int nlattr_to_sctp(struct nlattr *cda[], struct nf_conn *ct) | |||
530 | write_lock_bh(&sctp_lock); | 530 | write_lock_bh(&sctp_lock); |
531 | ct->proto.sctp.state = nla_get_u8(tb[CTA_PROTOINFO_SCTP_STATE]); | 531 | ct->proto.sctp.state = nla_get_u8(tb[CTA_PROTOINFO_SCTP_STATE]); |
532 | ct->proto.sctp.vtag[IP_CT_DIR_ORIGINAL] = | 532 | ct->proto.sctp.vtag[IP_CT_DIR_ORIGINAL] = |
533 | ntohl(nla_get_be32(tb[CTA_PROTOINFO_SCTP_VTAG_ORIGINAL])); | 533 | nla_get_be32(tb[CTA_PROTOINFO_SCTP_VTAG_ORIGINAL]); |
534 | ct->proto.sctp.vtag[IP_CT_DIR_REPLY] = | 534 | ct->proto.sctp.vtag[IP_CT_DIR_REPLY] = |
535 | ntohl(nla_get_be32(tb[CTA_PROTOINFO_SCTP_VTAG_REPLY])); | 535 | nla_get_be32(tb[CTA_PROTOINFO_SCTP_VTAG_REPLY]); |
536 | write_unlock_bh(&sctp_lock); | 536 | write_unlock_bh(&sctp_lock); |
537 | 537 | ||
538 | return 0; | 538 | return 0; |