diff options
author | Denis V. Lunev <den@openvz.org> | 2008-05-02 07:09:11 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-05-02 07:09:11 -0400 |
commit | 1d3faa390df9f009d7d76134b2aa1f07990945a4 (patch) | |
tree | df9941f3f636633f46968f35a8fbfa1f030c31c6 | |
parent | 0c89652a741cce71661d561c4466115c60c752d1 (diff) |
vlan: 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>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/8021q/vlanproc.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/net/8021q/vlanproc.c b/net/8021q/vlanproc.c index daad0064e2c2..08b54b593d56 100644 --- a/net/8021q/vlanproc.c +++ b/net/8021q/vlanproc.c | |||
@@ -176,12 +176,11 @@ int vlan_proc_add_dev(struct net_device *vlandev) | |||
176 | struct vlan_dev_info *dev_info = vlan_dev_info(vlandev); | 176 | struct vlan_dev_info *dev_info = vlan_dev_info(vlandev); |
177 | struct vlan_net *vn = net_generic(dev_net(vlandev), vlan_net_id); | 177 | struct vlan_net *vn = net_generic(dev_net(vlandev), vlan_net_id); |
178 | 178 | ||
179 | dev_info->dent = proc_create(vlandev->name, S_IFREG|S_IRUSR|S_IWUSR, | 179 | dev_info->dent = |
180 | vn->proc_vlan_dir, &vlandev_fops); | 180 | proc_create_data(vlandev->name, S_IFREG|S_IRUSR|S_IWUSR, |
181 | vn->proc_vlan_dir, &vlandev_fops, vlandev); | ||
181 | if (!dev_info->dent) | 182 | if (!dev_info->dent) |
182 | return -ENOBUFS; | 183 | return -ENOBUFS; |
183 | |||
184 | dev_info->dent->data = vlandev; | ||
185 | return 0; | 184 | return 0; |
186 | } | 185 | } |
187 | 186 | ||