[SCSI] ncr53c8xx: Call scsi_host_put in release
[deliverable/linux.git] / drivers / scsi / ncr53c8xx.c
index 030ba49f33ff3f4a338da8331456f47a0a9ebcff..91fa66c3ec98d453765e36f20659e18df877fe7c 100644 (file)
@@ -8528,18 +8528,15 @@ struct Scsi_Host * __init ncr_attach(struct scsi_host_template *tpnt,
 }
 
 
-int ncr53c8xx_release(struct Scsi_Host *host)
+void ncr53c8xx_release(struct Scsi_Host *host)
 {
-       struct host_data *host_data;
+       struct host_data *host_data = shost_priv(host);
 #ifdef DEBUG_NCR53C8XX
        printk("ncr53c8xx: release\n");
 #endif
-       if (!host)
-               return 1;
-       host_data = (struct host_data *)host->hostdata;
-       if (host_data && host_data->ncb)
+       if (host_data->ncb)
                ncr_detach(host_data->ncb);
-       return 1;
+       scsi_host_put(host);
 }
 
 static void ncr53c8xx_set_period(struct scsi_target *starget, int period)
This page took 0.024497 seconds and 5 git commands to generate.