]> err.no Git - linux-2.6/commitdiff
[NET]: Annotate callers of csum_partial_copy_...() and csum_and_copy...() in net/*
authorAl Viro <viro@zeniv.linux.org.uk>
Wed, 15 Nov 2006 05:36:34 +0000 (21:36 -0800)
committerDavid S. Miller <davem@sunset.davemloft.net>
Sun, 3 Dec 2006 05:23:33 +0000 (21:23 -0800)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/skbuff.h
include/net/sock.h
net/core/datagram.c
net/core/skbuff.c
net/ipv4/ip_output.c

index e3ae544b3956e9002bdc14bd6eb4e9a2242f54b3..64fa7f4c702dbb373254af88e5d15915ccf8ce40 100644 (file)
@@ -1199,8 +1199,7 @@ static inline int skb_add_data(struct sk_buff *skb,
 
        if (skb->ip_summed == CHECKSUM_NONE) {
                int err = 0;
-               unsigned int csum = csum_and_copy_from_user(from,
-                                                           skb_put(skb, copy),
+               __wsum csum = csum_and_copy_from_user(from, skb_put(skb, copy),
                                                            copy, 0, &err);
                if (!err) {
                        skb->csum = csum_block_add(skb->csum, csum, off);
index 35ffbdd35d3ec0c5b219af21d798143ffded7d92..dc4b92b8abea93068d231562288ab2563236e573 100644 (file)
@@ -1088,7 +1088,7 @@ static inline int skb_copy_to_page(struct sock *sk, char __user *from,
 {
        if (skb->ip_summed == CHECKSUM_NONE) {
                int err = 0;
-               unsigned int csum = csum_and_copy_from_user(from,
+               __wsum csum = csum_and_copy_from_user(from,
                                                     page_address(page) + off,
                                                            copy, 0, &err);
                if (err)
index e5a05a046fef185790dbb136551f1307e537b50e..0d9c9bac400623cd71c70053a0624100b47a5b04 100644 (file)
@@ -321,7 +321,7 @@ fault:
 
 static int skb_copy_and_csum_datagram(const struct sk_buff *skb, int offset,
                                      u8 __user *to, int len,
-                                     unsigned int *csump)
+                                     __wsum *csump)
 {
        int start = skb_headlen(skb);
        int pos = 0;
@@ -350,7 +350,7 @@ static int skb_copy_and_csum_datagram(const struct sk_buff *skb, int offset,
 
                end = start + skb_shinfo(skb)->frags[i].size;
                if ((copy = end - offset) > 0) {
-                       unsigned int csum2;
+                       __wsum csum2;
                        int err = 0;
                        u8  *vaddr;
                        skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
@@ -386,7 +386,7 @@ static int skb_copy_and_csum_datagram(const struct sk_buff *skb, int offset,
 
                        end = start + list->len;
                        if ((copy = end - offset) > 0) {
-                               unsigned int csum2 = 0;
+                               __wsum csum2 = 0;
                                if (copy > len)
                                        copy = len;
                                if (skb_copy_and_csum_datagram(list,
index c0e3427057fc52313461f66d0bd3872f1d5fa4ad..da6683f4b31dbf5ddf1a674193819857cfc28a78 100644 (file)
@@ -1342,7 +1342,7 @@ unsigned int skb_copy_and_csum_bits(const struct sk_buff *skb, int offset,
 
                end = start + skb_shinfo(skb)->frags[i].size;
                if ((copy = end - offset) > 0) {
-                       unsigned int csum2;
+                       __wsum csum2;
                        u8 *vaddr;
                        skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
 
index f9194f7e39d375a5ca64b42f24c19dfe1973f9b7..1da3d32f8289452fd22ee2e4586e8002068ab497 100644 (file)
@@ -1314,7 +1314,7 @@ void ip_flush_pending_frames(struct sock *sk)
 static int ip_reply_glue_bits(void *dptr, char *to, int offset, 
                              int len, int odd, struct sk_buff *skb)
 {
-       unsigned int csum;
+       __wsum csum;
 
        csum = csum_partial_copy_nocheck(dptr+offset, to, len, 0);
        skb->csum = csum_block_add(skb->csum, csum, odd);