mirror of
https://github.com/adulau/aha.git
synced 2024-12-29 04:06:22 +00:00
ipv6: assign PDE->data before gluing PDE into /proc tree
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>
This commit is contained in:
parent
5efdccbcda
commit
0bb53a66fe
1 changed files with 2 additions and 4 deletions
|
@ -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;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue