scsi: esas2r: Call scsi_done() directly

Conditional statements are faster than indirect calls. Hence call
scsi_done() directly.

Link: https://lore.kernel.org/r/20211007202923.2174984-31-bvanassche@acm.org
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
Bart Van Assche 2021-10-07 13:28:25 -07:00 committed by Martin K. Petersen
parent e6ed928eff
commit 52e65d1c25
1 changed files with 4 additions and 4 deletions

View File

@ -828,7 +828,7 @@ int esas2r_queuecommand(struct Scsi_Host *host, struct scsi_cmnd *cmd)
if (unlikely(test_bit(AF_DEGRADED_MODE, &a->flags))) {
cmd->result = DID_NO_CONNECT << 16;
cmd->scsi_done(cmd);
scsi_done(cmd);
return 0;
}
@ -988,7 +988,7 @@ int esas2r_eh_abort(struct scsi_cmnd *cmd)
scsi_set_resid(cmd, 0);
cmd->scsi_done(cmd);
scsi_done(cmd);
return SUCCESS;
}
@ -1054,7 +1054,7 @@ check_active_queue:
scsi_set_resid(cmd, 0);
cmd->scsi_done(cmd);
scsi_done(cmd);
return SUCCESS;
}
@ -1535,7 +1535,7 @@ void esas2r_complete_request_cb(struct esas2r_adapter *a,
scsi_set_resid(rq->cmd, 0);
}
rq->cmd->scsi_done(rq->cmd);
scsi_done(rq->cmd);
esas2r_free_request(a, rq);
}