lkml.org 
[lkml]   [2011]   [Jun]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[34-longterm 027/247] Staging: hv: fix sysfs symlink on hv block device
    Date
    From: Ky Srinivasan <ksrinivasan@novell.com>

    -------------------
    This is a commit scheduled for the next v2.6.34 longterm release.
    If you see a problem with using this for longterm, please comment.
    -------------------

    commit 268eff909afaca93188d2d14554cbf824f6a0e41 upstream.

    The block device does not create the proper symlink in sysfs because we
    forgot to set up the gendisk structure properly. This patch fixes the
    issue.

    Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
    Cc: Hank Janssen <hjanssen@microsoft.com>
    Cc: Haiyang Zhang <haiyangz@microsoft.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
    Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
    ---
    drivers/staging/hv/blkvsc_drv.c | 1 +
    1 files changed, 1 insertions(+), 0 deletions(-)

    diff --git a/drivers/staging/hv/blkvsc_drv.c b/drivers/staging/hv/blkvsc_drv.c
    index 8f1fda3..e917a46 100644
    --- a/drivers/staging/hv/blkvsc_drv.c
    +++ b/drivers/staging/hv/blkvsc_drv.c
    @@ -377,6 +377,7 @@ static int blkvsc_probe(struct device *device)
    blkdev->gd->first_minor = 0;
    blkdev->gd->fops = &block_ops;
    blkdev->gd->private_data = blkdev;
    + blkdev->gd->driverfs_dev = &(blkdev->device_ctx->device);
    sprintf(blkdev->gd->disk_name, "hd%c", 'a' + devnum);

    blkvsc_do_inquiry(blkdev);
    --
    1.7.4.4


    \
     
     \ /
      Last update: 2011-06-23 20:31    [W:0.026 / U:63.228 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site