Hi James,

A compile of the latest git on arm triggers the following warning:
  CC [M]  drivers/scsi/scsi_sysfs.o
  drivers/scsi/scsi_sysfs.c: In function `scsi_sysfs_add_sdev':
  drivers/scsi/scsi_sysfs.c:718: warning: unused variable `rq'

The following patch kills the intermediary variable.

Regards,
Frederik

Signed-off-by: Frederik Deweerdt <[EMAIL PROTECTED]>

diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c
index 34cdce6..9e5cc4f 100644
--- a/drivers/scsi/scsi_sysfs.c
+++ b/drivers/scsi/scsi_sysfs.c
@@ -715,7 +715,6 @@ static int attr_add(struct device *dev, struct 
device_attribute *attr)
 int scsi_sysfs_add_sdev(struct scsi_device *sdev)
 {
        int error, i;
-       struct request_queue *rq = sdev->request_queue;
 
        if ((error = scsi_device_set_state(sdev, SDEV_RUNNING)) != 0)
                return error;
@@ -736,7 +735,8 @@ int scsi_sysfs_add_sdev(struct scsi_device *sdev)
         * released by the sdev_class .release */
        get_device(&sdev->sdev_gendev);
 
-       error = bsg_register_queue(rq, &sdev->sdev_gendev, NULL);
+       error = bsg_register_queue(sdev->request_queue,
+                                  &sdev->sdev_gendev, NULL);
 
        if (error)
                sdev_printk(KERN_INFO, sdev,
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to