]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/scsi/scsi_proc.c
[SCSI] lpfc 8.2.8 v2 : Revert target busy in favor of transport disrupted
[linux-2.6-omap-h63xx.git] / drivers / scsi / scsi_proc.c
index e4a0d2f9b35752a47c2e84b7e99dafa67fce04f7..82f7b2dd08a23e934aa4d6e08ce76e3c84ab1dc4 100644 (file)
@@ -114,7 +114,7 @@ void scsi_proc_hostdir_add(struct scsi_host_template *sht)
                sht->proc_dir = proc_mkdir(sht->proc_name, proc_scsi);
                if (!sht->proc_dir)
                        printk(KERN_ERR "%s: proc_mkdir failed for %s\n",
-                              __FUNCTION__, sht->proc_name);
+                              __func__, sht->proc_name);
                else
                        sht->proc_dir->owner = sht->module;
        }
@@ -157,7 +157,7 @@ void scsi_proc_host_add(struct Scsi_Host *shost)
                        sht->proc_dir, proc_scsi_read, shost);
        if (!p) {
                printk(KERN_ERR "%s: Failed to register host %d in"
-                      "%s\n", __FUNCTION__, shost->host_no,
+                      "%s\n", __func__, shost->host_no,
                       sht->proc_name);
                return;
        } 
@@ -259,8 +259,8 @@ static int scsi_add_single_device(uint host, uint channel, uint id, uint lun)
        int error = -ENXIO;
 
        shost = scsi_host_lookup(host);
-       if (IS_ERR(shost))
-               return PTR_ERR(shost);
+       if (!shost)
+               return error;
 
        if (shost->transportt->user_scan)
                error = shost->transportt->user_scan(shost, channel, id, lun);
@@ -287,8 +287,8 @@ static int scsi_remove_single_device(uint host, uint channel, uint id, uint lun)
        int error = -ENXIO;
 
        shost = scsi_host_lookup(host);
-       if (IS_ERR(shost))
-               return PTR_ERR(shost);
+       if (!shost)
+               return error;
        sdev = scsi_device_lookup(shost, channel, id, lun);
        if (sdev) {
                scsi_remove_device(sdev);