Lines Matching refs:tmf_req

287 	mpt->tmf_req = mpt_get_request(mpt, FALSE);  in mpt_cam_attach()
288 if (mpt->tmf_req == NULL) { in mpt_cam_attach()
301 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_cam_attach()
1197 if (mpt->tmf_req != NULL) { in mpt_cam_detach()
1198 mpt->tmf_req->state = REQ_STATE_ALLOCATED; in mpt_cam_detach()
1199 mpt_free_request(mpt, mpt->tmf_req); in mpt_cam_detach()
1200 mpt->tmf_req = NULL; in mpt_cam_detach()
2225 error = mpt_wait_req(mpt, mpt->tmf_req, REQ_STATE_DONE, in mpt_bus_reset()
2228 status = le16toh(mpt->tmf_req->IOCStatus); in mpt_bus_reset()
2229 response = mpt->tmf_req->ResponseCode; in mpt_bus_reset()
2230 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_bus_reset()
2653 KASSERT(req == mpt->tmf_req, ("TMF Reply not using mpt->tmf_req")); in mpt_scsi_tmf_reply_handler()
2669 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_scsi_tmf_reply_handler()
3891 MSG_SCSI_TASK_MGMT *tmf_req; in mpt_scsi_send_tmf() local
3898 error = mpt_wait_req(mpt, mpt->tmf_req, REQ_STATE_FREE, REQ_STATE_FREE, in mpt_scsi_send_tmf()
3905 mpt_assign_serno(mpt, mpt->tmf_req); in mpt_scsi_send_tmf()
3906 mpt->tmf_req->state = REQ_STATE_ALLOCATED|REQ_STATE_QUEUED; in mpt_scsi_send_tmf()
3908 tmf_req = (MSG_SCSI_TASK_MGMT *)mpt->tmf_req->req_vbuf; in mpt_scsi_send_tmf()
3909 memset(tmf_req, 0, sizeof(*tmf_req)); in mpt_scsi_send_tmf()
3910 tmf_req->TargetID = target; in mpt_scsi_send_tmf()
3911 tmf_req->Bus = channel; in mpt_scsi_send_tmf()
3912 tmf_req->Function = MPI_FUNCTION_SCSI_TASK_MGMT; in mpt_scsi_send_tmf()
3913 tmf_req->TaskType = type; in mpt_scsi_send_tmf()
3914 tmf_req->MsgFlags = flags; in mpt_scsi_send_tmf()
3915 tmf_req->MsgContext = in mpt_scsi_send_tmf()
3916 htole32(mpt->tmf_req->index | scsi_tmf_handler_id); in mpt_scsi_send_tmf()
3917 be64enc(tmf_req->LUN, CAM_EXTLUN_BYTE_SWIZZLE(lun)); in mpt_scsi_send_tmf()
3918 tmf_req->TaskMsgContext = abort_ctx; in mpt_scsi_send_tmf()
3921 "Issuing TMF %p:%u with MsgContext of 0x%x\n", mpt->tmf_req, in mpt_scsi_send_tmf()
3922 mpt->tmf_req->serno, tmf_req->MsgContext); in mpt_scsi_send_tmf()
3924 mpt_print_request(tmf_req); in mpt_scsi_send_tmf()
3927 KASSERT(mpt_req_on_pending_list(mpt, mpt->tmf_req) == 0, in mpt_scsi_send_tmf()
3929 TAILQ_INSERT_HEAD(&mpt->request_pending_list, mpt->tmf_req, links); in mpt_scsi_send_tmf()
3930 error = mpt_send_handshake_cmd(mpt, sizeof(*tmf_req), tmf_req); in mpt_scsi_send_tmf()
3932 TAILQ_REMOVE(&mpt->request_pending_list, mpt->tmf_req, links); in mpt_scsi_send_tmf()
3933 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_scsi_send_tmf()
4039 error = mpt_wait_req(mpt, mpt->tmf_req, REQ_STATE_DONE, in mpt_recover_commands()
4042 status = le16toh(mpt->tmf_req->IOCStatus); in mpt_recover_commands()
4043 response = mpt->tmf_req->ResponseCode; in mpt_recover_commands()
4044 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_recover_commands()