[SCSI] remove spurious if tests from scsi_eh_{times_out|done}
authorTejun Heo <htejun@gmail.com>
Fri, 13 May 2005 15:46:18 +0000 (00:46 +0900)
committerJames Bottomley <jejb@mulgrave.(none)>
Fri, 20 May 2005 17:53:53 +0000 (12:53 -0500)
'if' tests which check if eh_action isn't NULL in both
functions are always true.  Remove the redundant if's as it
can give wrong impressions.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/scsi/scsi_error.c

index f5195cda5ef12c6e729b6a38b31ba45384e07e71..103558574662dd8e6c9cfa084f2a8cfecdd02b5e 100644 (file)
@@ -434,8 +434,7 @@ static void scsi_eh_times_out(struct scsi_cmnd *scmd)
        SCSI_LOG_ERROR_RECOVERY(3, printk("%s: scmd:%p\n", __FUNCTION__,
                                          scmd));
 
-       if (scmd->device->host->eh_action)
-               up(scmd->device->host->eh_action);
+       up(scmd->device->host->eh_action);
 }
 
 /**
@@ -457,8 +456,7 @@ static void scsi_eh_done(struct scsi_cmnd *scmd)
                SCSI_LOG_ERROR_RECOVERY(3, printk("%s scmd: %p result: %x\n",
                                           __FUNCTION__, scmd, scmd->result));
 
-               if (scmd->device->host->eh_action)
-                       up(scmd->device->host->eh_action);
+               up(scmd->device->host->eh_action);
        }
 }