Lines Matching refs:rtn
153 enum scsi_disposition rtn; in scmd_eh_abort_handler() local
166 rtn = scsi_try_to_abort_cmd(shost->hostt, scmd); in scmd_eh_abort_handler()
167 if (rtn != SUCCESS) { in scmd_eh_abort_handler()
171 (rtn == FAST_IO_FAIL) ? in scmd_eh_abort_handler()
331 enum blk_eh_timer_return rtn = BLK_EH_DONE; in scsi_timeout() local
342 rtn = host->hostt->eh_timed_out(scmd); in scsi_timeout()
344 if (rtn == BLK_EH_DONE) { in scsi_timeout()
365 return rtn; in scsi_timeout()
838 enum scsi_disposition rtn; in scsi_try_host_reset() local
848 rtn = hostt->eh_host_reset_handler(scmd); in scsi_try_host_reset()
850 if (rtn == SUCCESS) { in scsi_try_host_reset()
858 return rtn; in scsi_try_host_reset()
868 enum scsi_disposition rtn; in scsi_try_bus_reset() local
878 rtn = hostt->eh_bus_reset_handler(scmd); in scsi_try_bus_reset()
880 if (rtn == SUCCESS) { in scsi_try_bus_reset()
888 return rtn; in scsi_try_bus_reset()
910 enum scsi_disposition rtn; in scsi_try_target_reset() local
917 rtn = hostt->eh_target_reset_handler(scmd); in scsi_try_target_reset()
918 if (rtn == SUCCESS) { in scsi_try_target_reset()
925 return rtn; in scsi_try_target_reset()
940 enum scsi_disposition rtn; in scsi_try_bus_device_reset() local
946 rtn = hostt->eh_device_reset_handler(scmd); in scsi_try_bus_device_reset()
947 if (rtn == SUCCESS) in scsi_try_bus_device_reset()
949 return rtn; in scsi_try_bus_device_reset()
1111 int rtn; in scsi_send_eh_cmnd() local
1137 rtn = shost->hostt->queuecommand(shost, scmd); in scsi_send_eh_cmnd()
1139 rtn = FAILED; in scsi_send_eh_cmnd()
1142 if (rtn) { in scsi_send_eh_cmnd()
1152 rtn = FAILED; in scsi_send_eh_cmnd()
1155 rtn = SUCCESS; in scsi_send_eh_cmnd()
1160 scsi_log_completion(scmd, rtn); in scsi_send_eh_cmnd()
1176 rtn = scsi_eh_completed_normally(scmd); in scsi_send_eh_cmnd()
1178 "%s: scsi_eh_completed_normally %x\n", __func__, rtn)); in scsi_send_eh_cmnd()
1180 switch (rtn) { in scsi_send_eh_cmnd()
1186 rtn = NEEDS_RETRY; in scsi_send_eh_cmnd()
1189 rtn = FAILED; in scsi_send_eh_cmnd()
1192 } else if (rtn != FAILED) { in scsi_send_eh_cmnd()
1194 rtn = FAILED; in scsi_send_eh_cmnd()
1199 return rtn; in scsi_send_eh_cmnd()
1217 scsi_eh_action(struct scsi_cmnd *scmd, enum scsi_disposition rtn) in scsi_eh_action() argument
1222 rtn = sdrv->eh_action(scmd, rtn); in scsi_eh_action()
1224 return rtn; in scsi_eh_action()
1270 enum scsi_disposition rtn; in scsi_eh_get_sense() local
1301 rtn = scsi_request_sense(scmd); in scsi_eh_get_sense()
1302 if (rtn != SUCCESS) in scsi_eh_get_sense()
1309 rtn = scsi_decide_disposition(scmd); in scsi_eh_get_sense()
1315 if (rtn == SUCCESS) in scsi_eh_get_sense()
1328 else if (rtn != NEEDS_RETRY) in scsi_eh_get_sense()
1349 enum scsi_disposition rtn; in scsi_eh_tur() local
1352 rtn = scsi_send_eh_cmnd(scmd, tur_command, 6, in scsi_eh_tur()
1356 "%s return: %x\n", __func__, rtn)); in scsi_eh_tur()
1358 switch (rtn) { in scsi_eh_tur()
1438 enum scsi_disposition rtn = NEEDS_RETRY; in scsi_eh_try_stu() local
1440 for (i = 0; rtn == NEEDS_RETRY && i < 2; i++) in scsi_eh_try_stu()
1441 rtn = scsi_send_eh_cmnd(scmd, stu_command, 6, in scsi_eh_try_stu()
1444 if (rtn == SUCCESS) in scsi_eh_try_stu()
1533 enum scsi_disposition rtn; in scsi_eh_bus_device_reset() local
1557 rtn = scsi_try_bus_device_reset(bdr_scmd); in scsi_eh_bus_device_reset()
1558 if (rtn == SUCCESS || rtn == FAST_IO_FAIL) { in scsi_eh_bus_device_reset()
1560 rtn == FAST_IO_FAIL || in scsi_eh_bus_device_reset()
1565 scsi_eh_action(scmd, rtn) != FAILED) in scsi_eh_bus_device_reset()
1600 enum scsi_disposition rtn; in scsi_eh_target_reset() local
1621 rtn = scsi_try_target_reset(scmd); in scsi_eh_target_reset()
1622 if (rtn != SUCCESS && rtn != FAST_IO_FAIL) in scsi_eh_target_reset()
1632 if (rtn == SUCCESS) in scsi_eh_target_reset()
1634 else if (rtn == FAST_IO_FAIL) in scsi_eh_target_reset()
1658 enum scsi_disposition rtn; in scsi_eh_bus_reset() local
1695 rtn = scsi_try_bus_reset(chan_scmd); in scsi_eh_bus_reset()
1696 if (rtn == SUCCESS || rtn == FAST_IO_FAIL) { in scsi_eh_bus_reset()
1699 if (rtn == FAST_IO_FAIL) in scsi_eh_bus_reset()
1729 enum scsi_disposition rtn; in scsi_eh_host_reset() local
1740 rtn = scsi_try_host_reset(scmd); in scsi_eh_host_reset()
1741 if (rtn == SUCCESS) { in scsi_eh_host_reset()
1743 } else if (rtn == FAST_IO_FAIL) { in scsi_eh_host_reset()
1837 enum scsi_disposition rtn; in scsi_decide_disposition() local
1972 rtn = scsi_check_sense(scmd); in scsi_decide_disposition()
1973 if (rtn == NEEDS_RETRY) in scsi_decide_disposition()
1979 return rtn; in scsi_decide_disposition()
2390 enum scsi_disposition rtn; in scsi_ioctl_reset() local
2425 rtn = SUCCESS; in scsi_ioctl_reset()
2428 rtn = scsi_try_bus_device_reset(scmd); in scsi_ioctl_reset()
2429 if (rtn == SUCCESS || (val & SG_SCSI_RESET_NO_ESCALATE)) in scsi_ioctl_reset()
2433 rtn = scsi_try_target_reset(scmd); in scsi_ioctl_reset()
2434 if (rtn == SUCCESS || (val & SG_SCSI_RESET_NO_ESCALATE)) in scsi_ioctl_reset()
2438 rtn = scsi_try_bus_reset(scmd); in scsi_ioctl_reset()
2439 if (rtn == SUCCESS || (val & SG_SCSI_RESET_NO_ESCALATE)) in scsi_ioctl_reset()
2443 rtn = scsi_try_host_reset(scmd); in scsi_ioctl_reset()
2444 if (rtn == SUCCESS) in scsi_ioctl_reset()
2448 rtn = FAILED; in scsi_ioctl_reset()
2452 error = (rtn == SUCCESS) ? 0 : -EIO; in scsi_ioctl_reset()