aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/udp.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2006-11-15 00:35:48 -0500
committerDavid S. Miller <davem@sunset.davemloft.net>2006-12-03 00:23:31 -0500
commit868c86bcb5bdea7ed8d45979b17bb919af9254db (patch)
treeebc232092d6a8a75261a9e3f698206cc09740fdf /net/ipv6/udp.c
parent2bda2853150e20ca2a44627d00b5f85af0b24a42 (diff)
[NET]: annotate csum_ipv6_magic() callers in net/*
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/udp.c')
-rw-r--r--net/ipv6/udp.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
index e6e1f85f1bbd..0d22008d522e 100644
--- a/net/ipv6/udp.c
+++ b/net/ipv6/udp.c
@@ -383,9 +383,10 @@ static inline int udp6_csum_init(struct sk_buff *skb, struct udphdr *uh)
383 skb->ip_summed = CHECKSUM_UNNECESSARY; 383 skb->ip_summed = CHECKSUM_UNNECESSARY;
384 384
385 if (skb->ip_summed != CHECKSUM_UNNECESSARY) 385 if (skb->ip_summed != CHECKSUM_UNNECESSARY)
386 skb->csum = ~csum_ipv6_magic(&skb->nh.ipv6h->saddr, 386 skb->csum = ~csum_unfold(csum_ipv6_magic(&skb->nh.ipv6h->saddr,
387 &skb->nh.ipv6h->daddr, 387 &skb->nh.ipv6h->daddr,
388 skb->len, IPPROTO_UDP, 0); 388 ulen, IPPROTO_UDP,
389 0));
389 390
390 return (UDP_SKB_CB(skb)->partial_cov = 0); 391 return (UDP_SKB_CB(skb)->partial_cov = 0);
391} 392}
@@ -511,7 +512,7 @@ static int udp_v6_push_pending_frames(struct sock *sk, struct udp_sock *up)
511 struct inet_sock *inet = inet_sk(sk); 512 struct inet_sock *inet = inet_sk(sk);
512 struct flowi *fl = &inet->cork.fl; 513 struct flowi *fl = &inet->cork.fl;
513 int err = 0; 514 int err = 0;
514 u32 csum = 0; 515 __wsum csum = 0;
515 516
516 /* Grab the skbuff where UDP header space exists. */ 517 /* Grab the skbuff where UDP header space exists. */
517 if ((skb = skb_peek(&sk->sk_write_queue)) == NULL) 518 if ((skb = skb_peek(&sk->sk_write_queue)) == NULL)