mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-17 02:31:27 +00:00
Small improvements
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1907 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -434,16 +434,18 @@ static int scst_local_send_resp(struct scsi_cmnd *cmnd,
|
||||
|
||||
TRACE_ENTRY();
|
||||
|
||||
if (cmnd && scst_cmnd) {
|
||||
if (scst_cmnd) {
|
||||
/* The buffer isn't ours, so let's be safe and restore it */
|
||||
scst_check_restore_sg_buff(scst_cmnd);
|
||||
|
||||
/* Simulate autosense by this driver */
|
||||
if (SAM_STAT_CHECK_CONDITION == (scsi_result & 0xFF))
|
||||
if (unlikely(SCST_SENSE_VALID(scst_cmnd->sense)))
|
||||
copy_sense(cmnd, scst_cmnd);
|
||||
}
|
||||
|
||||
if (cmnd)
|
||||
cmnd->result = scsi_result;
|
||||
if (done)
|
||||
done(cmnd);
|
||||
cmnd->result = scsi_result;
|
||||
|
||||
done(cmnd);
|
||||
|
||||
TRACE_EXIT_RES(ret);
|
||||
return ret;
|
||||
|
||||
Reference in New Issue
Block a user