aboutsummaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2006-11-14 21:40:42 -0800
committerDavid S. Miller <davem@sunset.davemloft.net>2006-12-02 21:23:38 -0800
commitb51655b958dfb1176bfcf99466231fdbef8751ff (patch)
treea53d0ec00d8db4169ba8c1c487fffbd34d6dde03 /include/linux
parentb1550f221255f7dd06048d832bf0f3d166840e1c (diff)
[NET]: Annotate __skb_checksum_complete() and friends.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/netfilter.h6
-rw-r--r--include/linux/netfilter_ipv4.h2
-rw-r--r--include/linux/netfilter_ipv6.h2
-rw-r--r--include/linux/skbuff.h2
4 files changed, 6 insertions, 6 deletions
diff --git a/include/linux/netfilter.h b/include/linux/netfilter.h
index b7e67d1d438..707bb2e53c4 100644
--- a/include/linux/netfilter.h
+++ b/include/linux/netfilter.h
@@ -290,7 +290,7 @@ extern u_int16_t nf_proto_csum_update(struct sk_buff *skb,
struct nf_afinfo {
unsigned short family;
- unsigned int (*checksum)(struct sk_buff *skb, unsigned int hook,
+ __sum16 (*checksum)(struct sk_buff *skb, unsigned int hook,
unsigned int dataoff, u_int8_t protocol);
void (*saveroute)(const struct sk_buff *skb,
struct nf_info *info);
@@ -305,12 +305,12 @@ static inline struct nf_afinfo *nf_get_afinfo(unsigned short family)
return rcu_dereference(nf_afinfo[family]);
}
-static inline unsigned int
+static inline __sum16
nf_checksum(struct sk_buff *skb, unsigned int hook, unsigned int dataoff,
u_int8_t protocol, unsigned short family)
{
struct nf_afinfo *afinfo;
- unsigned int csum = 0;
+ __sum16 csum = 0;
rcu_read_lock();
afinfo = nf_get_afinfo(family);
diff --git a/include/linux/netfilter_ipv4.h b/include/linux/netfilter_ipv4.h
index 5b63a231a76..5821eb5a0a3 100644
--- a/include/linux/netfilter_ipv4.h
+++ b/include/linux/netfilter_ipv4.h
@@ -79,7 +79,7 @@ enum nf_ip_hook_priorities {
#ifdef __KERNEL__
extern int ip_route_me_harder(struct sk_buff **pskb, unsigned addr_type);
extern int ip_xfrm_me_harder(struct sk_buff **pskb);
-extern unsigned int nf_ip_checksum(struct sk_buff *skb, unsigned int hook,
+extern __sum16 nf_ip_checksum(struct sk_buff *skb, unsigned int hook,
unsigned int dataoff, u_int8_t protocol);
#endif /*__KERNEL__*/
diff --git a/include/linux/netfilter_ipv6.h b/include/linux/netfilter_ipv6.h
index d97e268cdfe..ab81a6dc94e 100644
--- a/include/linux/netfilter_ipv6.h
+++ b/include/linux/netfilter_ipv6.h
@@ -74,7 +74,7 @@ enum nf_ip6_hook_priorities {
#ifdef CONFIG_NETFILTER
extern int ip6_route_me_harder(struct sk_buff *skb);
-extern unsigned int nf_ip6_checksum(struct sk_buff *skb, unsigned int hook,
+extern __sum16 nf_ip6_checksum(struct sk_buff *skb, unsigned int hook,
unsigned int dataoff, u_int8_t protocol);
extern int ipv6_netfilter_init(void);
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index 874ca029fbb..41753667541 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
@@ -1398,7 +1398,7 @@ static inline void skb_set_timestamp(struct sk_buff *skb, const struct timeval *
extern void __net_timestamp(struct sk_buff *skb);
-extern unsigned int __skb_checksum_complete(struct sk_buff *skb);
+extern __sum16 __skb_checksum_complete(struct sk_buff *skb);
/**
* skb_checksum_complete - Calculate checksum of an entire packet