@@ -70,21 +70,18 @@ bfa_cb_ioim_done(void *drv, struct bfad_ioim_s *dio,
70
70
host_status = DID_ERROR ;
71
71
}
72
72
}
73
- cmnd -> result = ScsiResult ( host_status , scsi_status ) ;
73
+ cmnd -> result = host_status << 16 | scsi_status ;
74
74
75
75
break ;
76
76
77
77
case BFI_IOIM_STS_TIMEDOUT :
78
- host_status = DID_TIME_OUT ;
79
- cmnd -> result = ScsiResult (host_status , 0 );
78
+ cmnd -> result = DID_TIME_OUT << 16 ;
80
79
break ;
81
80
case BFI_IOIM_STS_PATHTOV :
82
- host_status = DID_TRANSPORT_DISRUPTED ;
83
- cmnd -> result = ScsiResult (host_status , 0 );
81
+ cmnd -> result = DID_TRANSPORT_DISRUPTED << 16 ;
84
82
break ;
85
83
default :
86
- host_status = DID_ERROR ;
87
- cmnd -> result = ScsiResult (host_status , 0 );
84
+ cmnd -> result = DID_ERROR << 16 ;
88
85
}
89
86
90
87
/* Unmap DMA, if host is NULL, it means a scsi passthru cmd */
@@ -117,7 +114,7 @@ bfa_cb_ioim_good_comp(void *drv, struct bfad_ioim_s *dio)
117
114
struct bfad_itnim_data_s * itnim_data ;
118
115
struct bfad_itnim_s * itnim ;
119
116
120
- cmnd -> result = ScsiResult ( DID_OK , SCSI_STATUS_GOOD ) ;
117
+ cmnd -> result = DID_OK << 16 | SCSI_STATUS_GOOD ;
121
118
122
119
/* Unmap DMA, if host is NULL, it means a scsi passthru cmd */
123
120
if (cmnd -> device -> host != NULL )
@@ -144,7 +141,7 @@ bfa_cb_ioim_abort(void *drv, struct bfad_ioim_s *dio)
144
141
struct scsi_cmnd * cmnd = (struct scsi_cmnd * )dio ;
145
142
struct bfad_s * bfad = drv ;
146
143
147
- cmnd -> result = ScsiResult ( DID_ERROR , 0 ) ;
144
+ cmnd -> result = DID_ERROR << 16 ;
148
145
149
146
/* Unmap DMA, if host is NULL, it means a scsi passthru cmd */
150
147
if (cmnd -> device -> host != NULL )
@@ -1253,14 +1250,14 @@ bfad_im_queuecommand_lck(struct scsi_cmnd *cmnd, void (*done) (struct scsi_cmnd
1253
1250
printk (KERN_WARNING
1254
1251
"bfad%d, queuecommand %p %x failed, BFA stopped\n" ,
1255
1252
bfad -> inst_no , cmnd , cmnd -> cmnd [0 ]);
1256
- cmnd -> result = ScsiResult ( DID_NO_CONNECT , 0 ) ;
1253
+ cmnd -> result = DID_NO_CONNECT << 16 ;
1257
1254
goto out_fail_cmd ;
1258
1255
}
1259
1256
1260
1257
1261
1258
itnim = itnim_data -> itnim ;
1262
1259
if (!itnim ) {
1263
- cmnd -> result = ScsiResult ( DID_IMM_RETRY , 0 ) ;
1260
+ cmnd -> result = DID_IMM_RETRY << 16 ;
1264
1261
goto out_fail_cmd ;
1265
1262
}
1266
1263
0 commit comments