]> err.no Git - linux-2.6/blobdiff - drivers/scsi/scsi_sysfs.c
JFS: Fix regression. fsck complains if symlinks do not have INLINEEA attribute
[linux-2.6] / drivers / scsi / scsi_sysfs.c
index ea7f3a43357235f3287efe594e41f9799b2fa0aa..a77b32deaf8fdb732d45371a0eacf2c73a28d672 100644 (file)
@@ -106,7 +106,10 @@ static int scsi_scan(struct Scsi_Host *shost, const char *str)
                return -EINVAL;
        if (check_set(&lun, s3))
                return -EINVAL;
-       res = scsi_scan_host_selected(shost, channel, id, lun, 1);
+       if (shost->transportt->user_scan)
+               res = shost->transportt->user_scan(shost, channel, id, lun);
+       else
+               res = scsi_scan_host_selected(shost, channel, id, lun, 1);
        return res;
 }
 
@@ -745,9 +748,9 @@ void scsi_remove_device(struct scsi_device *sdev)
 {
        struct Scsi_Host *shost = sdev->host;
 
-       down(&shost->scan_mutex);
+       mutex_lock(&shost->scan_mutex);
        __scsi_remove_device(sdev);
-       up(&shost->scan_mutex);
+       mutex_unlock(&shost->scan_mutex);
 }
 EXPORT_SYMBOL(scsi_remove_device);