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()
896 enum scsi_disposition rtn; in scsi_try_host_reset() local
906 rtn = hostt->eh_host_reset_handler(scmd); in scsi_try_host_reset()
908 if (rtn == SUCCESS) { in scsi_try_host_reset()
916 return rtn; in scsi_try_host_reset()
926 enum scsi_disposition rtn; in scsi_try_bus_reset() local
936 rtn = hostt->eh_bus_reset_handler(scmd); in scsi_try_bus_reset()
938 if (rtn == SUCCESS) { in scsi_try_bus_reset()
946 return rtn; in scsi_try_bus_reset()
968 enum scsi_disposition rtn; in scsi_try_target_reset() local
975 rtn = hostt->eh_target_reset_handler(scmd); in scsi_try_target_reset()
976 if (rtn == SUCCESS) { in scsi_try_target_reset()
983 return rtn; in scsi_try_target_reset()
998 enum scsi_disposition rtn; in scsi_try_bus_device_reset() local
1004 rtn = hostt->eh_device_reset_handler(scmd); in scsi_try_bus_device_reset()
1005 if (rtn == SUCCESS) in scsi_try_bus_device_reset()
1007 return rtn; in scsi_try_bus_device_reset()
1169 int rtn; in scsi_send_eh_cmnd() local
1196 rtn = shost->hostt->queuecommand(shost, scmd); in scsi_send_eh_cmnd()
1198 rtn = FAILED; in scsi_send_eh_cmnd()
1201 if (rtn) { in scsi_send_eh_cmnd()
1211 rtn = FAILED; in scsi_send_eh_cmnd()
1214 rtn = SUCCESS; in scsi_send_eh_cmnd()
1219 scsi_log_completion(scmd, rtn); in scsi_send_eh_cmnd()
1235 rtn = scsi_eh_completed_normally(scmd); in scsi_send_eh_cmnd()
1237 "%s: scsi_eh_completed_normally %x\n", __func__, rtn)); in scsi_send_eh_cmnd()
1239 switch (rtn) { in scsi_send_eh_cmnd()
1245 rtn = NEEDS_RETRY; in scsi_send_eh_cmnd()
1248 rtn = FAILED; in scsi_send_eh_cmnd()
1251 } else if (rtn != FAILED) { in scsi_send_eh_cmnd()
1253 rtn = FAILED; in scsi_send_eh_cmnd()
1258 return rtn; in scsi_send_eh_cmnd()
1276 scsi_eh_action(struct scsi_cmnd *scmd, enum scsi_disposition rtn) in scsi_eh_action() argument
1281 rtn = sdrv->eh_action(scmd, rtn); in scsi_eh_action()
1283 return rtn; in scsi_eh_action()
1329 enum scsi_disposition rtn; in scsi_eh_get_sense() local
1360 rtn = scsi_request_sense(scmd); in scsi_eh_get_sense()
1361 if (rtn != SUCCESS) in scsi_eh_get_sense()
1368 rtn = scsi_decide_disposition(scmd); in scsi_eh_get_sense()
1374 if (rtn == SUCCESS) in scsi_eh_get_sense()
1387 else if (rtn != NEEDS_RETRY) in scsi_eh_get_sense()
1408 enum scsi_disposition rtn; in scsi_eh_tur() local
1411 rtn = scsi_send_eh_cmnd(scmd, tur_command, 6, in scsi_eh_tur()
1415 "%s return: %x\n", __func__, rtn)); in scsi_eh_tur()
1417 switch (rtn) { in scsi_eh_tur()
1497 enum scsi_disposition rtn = NEEDS_RETRY; in scsi_eh_try_stu() local
1499 for (i = 0; rtn == NEEDS_RETRY && i < 2; i++) in scsi_eh_try_stu()
1500 rtn = scsi_send_eh_cmnd(scmd, stu_command, 6, in scsi_eh_try_stu()
1503 if (rtn == SUCCESS) in scsi_eh_try_stu()
1592 enum scsi_disposition rtn; in scsi_eh_bus_device_reset() local
1616 rtn = scsi_try_bus_device_reset(bdr_scmd); in scsi_eh_bus_device_reset()
1617 if (rtn == SUCCESS || rtn == FAST_IO_FAIL) { in scsi_eh_bus_device_reset()
1619 rtn == FAST_IO_FAIL || in scsi_eh_bus_device_reset()
1624 scsi_eh_action(scmd, rtn) != FAILED) in scsi_eh_bus_device_reset()
1659 enum scsi_disposition rtn; in scsi_eh_target_reset() local
1680 rtn = scsi_try_target_reset(scmd); in scsi_eh_target_reset()
1681 if (rtn != SUCCESS && rtn != FAST_IO_FAIL) in scsi_eh_target_reset()
1691 if (rtn == SUCCESS) in scsi_eh_target_reset()
1693 else if (rtn == FAST_IO_FAIL) in scsi_eh_target_reset()
1717 enum scsi_disposition rtn; in scsi_eh_bus_reset() local
1754 rtn = scsi_try_bus_reset(chan_scmd); in scsi_eh_bus_reset()
1755 if (rtn == SUCCESS || rtn == FAST_IO_FAIL) { in scsi_eh_bus_reset()
1758 if (rtn == FAST_IO_FAIL) in scsi_eh_bus_reset()
1788 enum scsi_disposition rtn; in scsi_eh_host_reset() local
1799 rtn = scsi_try_host_reset(scmd); in scsi_eh_host_reset()
1800 if (rtn == SUCCESS) { in scsi_eh_host_reset()
1802 } else if (rtn == FAST_IO_FAIL) { in scsi_eh_host_reset()
1900 enum scsi_disposition rtn; in scsi_decide_disposition() local
2043 rtn = scsi_check_sense(scmd); in scsi_decide_disposition()
2044 if (rtn == NEEDS_RETRY) in scsi_decide_disposition()
2050 return rtn; in scsi_decide_disposition()
2465 enum scsi_disposition rtn; in scsi_ioctl_reset() local
2501 rtn = SUCCESS; in scsi_ioctl_reset()
2504 rtn = scsi_try_bus_device_reset(scmd); in scsi_ioctl_reset()
2505 if (rtn == SUCCESS || (val & SG_SCSI_RESET_NO_ESCALATE)) in scsi_ioctl_reset()
2509 rtn = scsi_try_target_reset(scmd); in scsi_ioctl_reset()
2510 if (rtn == SUCCESS || (val & SG_SCSI_RESET_NO_ESCALATE)) in scsi_ioctl_reset()
2514 rtn = scsi_try_bus_reset(scmd); in scsi_ioctl_reset()
2515 if (rtn == SUCCESS || (val & SG_SCSI_RESET_NO_ESCALATE)) in scsi_ioctl_reset()
2519 rtn = scsi_try_host_reset(scmd); in scsi_ioctl_reset()
2520 if (rtn == SUCCESS) in scsi_ioctl_reset()
2524 rtn = FAILED; in scsi_ioctl_reset()
2528 error = (rtn == SUCCESS) ? 0 : -EIO; in scsi_ioctl_reset()