WorkStruct: make allyesconfig
[deliverable/linux.git] / net / core / netpoll.c
index 9308af060b44d61284d6ce654b82029dbc0d6738..63f24c914ddb561b240bcabf7a8e66574d368c5f 100644 (file)
@@ -56,7 +56,7 @@ static atomic_t trapped;
 static void zap_completion_queue(void);
 static void arp_reply(struct sk_buff *skb);
 
-static void queue_process(void *p)
+static void queue_process(struct work_struct *work)
 {
        unsigned long flags;
        struct sk_buff *skb;
@@ -77,7 +77,7 @@ static void queue_process(void *p)
        }
 }
 
-static DECLARE_WORK(send_queue, queue_process, NULL);
+static DECLARE_WORK(send_queue, queue_process);
 
 void netpoll_queue(struct sk_buff *skb)
 {
@@ -340,6 +340,12 @@ void netpoll_send_udp(struct netpoll *np, const char *msg, int len)
        udph->dest = htons(np->remote_port);
        udph->len = htons(udp_len);
        udph->check = 0;
+       udph->check = csum_tcpudp_magic(htonl(np->local_ip),
+                                       htonl(np->remote_ip),
+                                       udp_len, IPPROTO_UDP,
+                                       csum_partial((unsigned char *)udph, udp_len, 0));
+       if (udph->check == 0)
+               udph->check = -1;
 
        skb->nh.iph = iph = (struct iphdr *)skb_push(skb, sizeof(*iph));
 
This page took 0.024549 seconds and 5 git commands to generate.