summaryrefslogtreecommitdiff
path: root/drivers/scsi/bfa/bfad_im.c
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2021-10-07 23:28:19 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2021-10-17 04:28:45 +0300
commit4316b5b8b2c69d7d2f526ee5659b00ecb0abacbe (patch)
tree3a870cbec4315ea83f8aab1f7dc7533a7200d438 /drivers/scsi/bfa/bfad_im.c
parent681fa5252fd4ba4d9fa77218c56c7ce9e411d72c (diff)
downloadlinux-4316b5b8b2c69d7d2f526ee5659b00ecb0abacbe.tar.xz
scsi: bfa: Call scsi_done() directly
Conditional statements are faster than indirect calls. Hence call scsi_done() directly. Link: https://lore.kernel.org/r/20211007202923.2174984-25-bvanassche@acm.org Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/bfa/bfad_im.c')
-rw-r--r--drivers/scsi/bfa/bfad_im.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/scsi/bfa/bfad_im.c b/drivers/scsi/bfa/bfad_im.c
index 6b5841b1c06e..e12ae60efd33 100644
--- a/drivers/scsi/bfa/bfad_im.c
+++ b/drivers/scsi/bfa/bfad_im.c
@@ -96,7 +96,7 @@ bfa_cb_ioim_done(void *drv, struct bfad_ioim_s *dio,
}
}
- cmnd->scsi_done(cmnd);
+ scsi_done(cmnd);
}
void
@@ -124,7 +124,7 @@ bfa_cb_ioim_good_comp(void *drv, struct bfad_ioim_s *dio)
}
}
- cmnd->scsi_done(cmnd);
+ scsi_done(cmnd);
}
void
@@ -226,7 +226,7 @@ bfad_im_abort_handler(struct scsi_cmnd *cmnd)
timeout *= 2;
}
- cmnd->scsi_done(cmnd);
+ scsi_done(cmnd);
bfa_trc(bfad, hal_io->iotag);
BFA_LOG(KERN_INFO, bfad, bfa_log_level,
"scsi%d: complete abort 0x%p iotag 0x%x\n",
@@ -1233,8 +1233,6 @@ bfad_im_queuecommand_lck(struct scsi_cmnd *cmnd, void (*done) (struct scsi_cmnd
if (sg_cnt < 0)
return SCSI_MLQUEUE_HOST_BUSY;
- cmnd->scsi_done = done;
-
spin_lock_irqsave(&bfad->bfad_lock, flags);
if (!(bfad->bfad_flags & BFAD_HAL_START_DONE)) {
printk(KERN_WARNING