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()
2224 error = mpt_wait_req(mpt, mpt->tmf_req, REQ_STATE_DONE, in mpt_bus_reset()
2227 status = le16toh(mpt->tmf_req->IOCStatus); in mpt_bus_reset()
2228 response = mpt->tmf_req->ResponseCode; in mpt_bus_reset()
2229 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_bus_reset()
2650 KASSERT(req == mpt->tmf_req, ("TMF Reply not using mpt->tmf_req")); in mpt_scsi_tmf_reply_handler()
2666 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_scsi_tmf_reply_handler()
3888 MSG_SCSI_TASK_MGMT *tmf_req; in mpt_scsi_send_tmf() local
3895 error = mpt_wait_req(mpt, mpt->tmf_req, REQ_STATE_FREE, REQ_STATE_FREE, in mpt_scsi_send_tmf()
3902 mpt_assign_serno(mpt, mpt->tmf_req); in mpt_scsi_send_tmf()
3903 mpt->tmf_req->state = REQ_STATE_ALLOCATED|REQ_STATE_QUEUED; in mpt_scsi_send_tmf()
3905 tmf_req = (MSG_SCSI_TASK_MGMT *)mpt->tmf_req->req_vbuf; in mpt_scsi_send_tmf()
3906 memset(tmf_req, 0, sizeof(*tmf_req)); in mpt_scsi_send_tmf()
3907 tmf_req->TargetID = target; in mpt_scsi_send_tmf()
3908 tmf_req->Bus = channel; in mpt_scsi_send_tmf()
3909 tmf_req->Function = MPI_FUNCTION_SCSI_TASK_MGMT; in mpt_scsi_send_tmf()
3910 tmf_req->TaskType = type; in mpt_scsi_send_tmf()
3911 tmf_req->MsgFlags = flags; in mpt_scsi_send_tmf()
3912 tmf_req->MsgContext = in mpt_scsi_send_tmf()
3913 htole32(mpt->tmf_req->index | scsi_tmf_handler_id); in mpt_scsi_send_tmf()
3914 be64enc(tmf_req->LUN, CAM_EXTLUN_BYTE_SWIZZLE(lun)); in mpt_scsi_send_tmf()
3915 tmf_req->TaskMsgContext = abort_ctx; in mpt_scsi_send_tmf()
3918 "Issuing TMF %p:%u with MsgContext of 0x%x\n", mpt->tmf_req, in mpt_scsi_send_tmf()
3919 mpt->tmf_req->serno, tmf_req->MsgContext); in mpt_scsi_send_tmf()
3921 mpt_print_request(tmf_req); in mpt_scsi_send_tmf()
3924 KASSERT(mpt_req_on_pending_list(mpt, mpt->tmf_req) == 0, in mpt_scsi_send_tmf()
3926 TAILQ_INSERT_HEAD(&mpt->request_pending_list, mpt->tmf_req, links); in mpt_scsi_send_tmf()
3927 error = mpt_send_handshake_cmd(mpt, sizeof(*tmf_req), tmf_req); in mpt_scsi_send_tmf()
3929 TAILQ_REMOVE(&mpt->request_pending_list, mpt->tmf_req, links); in mpt_scsi_send_tmf()
3930 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_scsi_send_tmf()
4035 error = mpt_wait_req(mpt, mpt->tmf_req, REQ_STATE_DONE, in mpt_recover_commands()
4038 status = le16toh(mpt->tmf_req->IOCStatus); in mpt_recover_commands()
4039 response = mpt->tmf_req->ResponseCode; in mpt_recover_commands()
4040 mpt->tmf_req->state = REQ_STATE_FREE; in mpt_recover_commands()