lkml.org 
[lkml]   [2008]   [Apr]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 6/12] vlan: assign PDE->data before gluing PDE into /proc tree
    Date
    Simply replace proc_create and further data assigned with proc_create_data.

    Signed-off-by: Denis V. Lunev <den@openvz.org>
    Cc: Alexey Dobriyan <adobriyan@openvz.org>
    Cc: Eric W. Biederman <ebiederm@xmission.com>
    Cc: Patrick McHardy <kaber@trash.net>
    ---
    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 daad006..08b54b5 100644
    --- a/net/8021q/vlanproc.c
    +++ b/net/8021q/vlanproc.c
    @@ -176,12 +176,11 @@ int vlan_proc_add_dev(struct net_device *vlandev)
    struct vlan_dev_info *dev_info = vlan_dev_info(vlandev);
    struct vlan_net *vn = net_generic(dev_net(vlandev), vlan_net_id);

    - dev_info->dent = proc_create(vlandev->name, S_IFREG|S_IRUSR|S_IWUSR,
    - vn->proc_vlan_dir, &vlandev_fops);
    + dev_info->dent =
    + proc_create_data(vlandev->name, S_IFREG|S_IRUSR|S_IWUSR,
    + vn->proc_vlan_dir, &vlandev_fops, vlandev);
    if (!dev_info->dent)
    return -ENOBUFS;
    -
    - dev_info->dent->data = vlandev;
    return 0;
    }

    --
    1.5.3.rc5


    \
     
     \ /
      Last update: 2008-04-29 13:17    [W:0.018 / U:60.752 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site