[PATCH] remove many unneeded #includes of sched.h
[cascardo/linux.git] / net / ipv4 / tcp_probe.c
index 4be336f..61f406f 100644 (file)
@@ -30,7 +30,7 @@
 
 #include <net/tcp.h>
 
-MODULE_AUTHOR("Stephen Hemminger <shemminger@osdl.org>");
+MODULE_AUTHOR("Stephen Hemminger <shemminger@linux-foundation.org>");
 MODULE_DESCRIPTION("TCP cwnd snooper");
 MODULE_LICENSE("GPL");
 
@@ -143,7 +143,7 @@ out_free:
        return error ? error : cnt;
 }
 
-static struct file_operations tcpprobe_fops = {
+static const struct file_operations tcpprobe_fops = {
        .owner   = THIS_MODULE,
        .open    = tcpprobe_open,
        .read    = tcpprobe_read,
@@ -156,6 +156,8 @@ static __init int tcpprobe_init(void)
        init_waitqueue_head(&tcpw.wait);
        spin_lock_init(&tcpw.lock);
        tcpw.fifo = kfifo_alloc(bufsize, GFP_KERNEL, &tcpw.lock);
+       if (IS_ERR(tcpw.fifo))
+               return PTR_ERR(tcpw.fifo);
 
        if (!proc_net_fops_create(procname, S_IRUSR, &tcpprobe_fops))
                goto err0;