Commit 0c89652a authored by Denis V. Lunev's avatar Denis V. Lunev Committed by David S. Miller

atm: assign PDE->data before gluing PDE into /proc tree

Simply replace proc_create and further data assigned with proc_create_data.
proc_atm_dev_ops holds proper referrence.
Signed-off-by: default avatarDenis V. Lunev <den@openvz.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 0bb53a66
...@@ -417,12 +417,10 @@ int atm_proc_dev_register(struct atm_dev *dev) ...@@ -417,12 +417,10 @@ int atm_proc_dev_register(struct atm_dev *dev)
goto err_out; goto err_out;
sprintf(dev->proc_name,"%s:%d",dev->type, dev->number); sprintf(dev->proc_name,"%s:%d",dev->type, dev->number);
dev->proc_entry = proc_create(dev->proc_name, 0, atm_proc_root, dev->proc_entry = proc_create_data(dev->proc_name, 0, atm_proc_root,
&proc_atm_dev_ops); &proc_atm_dev_ops, dev);
if (!dev->proc_entry) if (!dev->proc_entry)
goto err_free_name; goto err_free_name;
dev->proc_entry->data = dev;
dev->proc_entry->owner = THIS_MODULE;
return 0; return 0;
err_free_name: err_free_name:
kfree(dev->proc_name); kfree(dev->proc_name);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment