]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
ipv6: assign PDE->data before gluing PDE into /proc tree
authorDenis V. Lunev <den@openvz.org>
Fri, 2 May 2008 09:46:55 +0000 (02:46 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 2 May 2008 09:46:55 +0000 (02:46 -0700)
Simply replace proc_create and further data assigned with proc_create_data.

Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/proc.c

index ca8b82f96fe5797625dfad774184ab128af54ee7..df0736a4cafacf9fac66459a5d1e390b54857be7 100644 (file)
@@ -247,13 +247,11 @@ int snmp6_register_dev(struct inet6_dev *idev)
        if (!proc_net_devsnmp6)
                return -ENOENT;
 
-       p = proc_create(idev->dev->name, S_IRUGO,
-                       proc_net_devsnmp6, &snmp6_seq_fops);
+       p = proc_create_data(idev->dev->name, S_IRUGO,
+                            proc_net_devsnmp6, &snmp6_seq_fops, idev);
        if (!p)
                return -ENOMEM;
 
-       p->data = idev;
-
        idev->stats.proc_dir_entry = p;
        return 0;
 }