Lines Matching refs:vm_srb
323 struct vmscsi_request vm_srb; member
989 static void storvsc_handle_error(struct vmscsi_request *vm_srb, in storvsc_handle_error() argument
999 switch (SRB_STATUS(vm_srb->srb_status)) { in storvsc_handle_error()
1006 if (vm_srb->srb_status & SRB_STATUS_AUTOSENSE_VALID) in storvsc_handle_error()
1036 if (vm_srb->srb_status & SRB_STATUS_AUTOSENSE_VALID && in storvsc_handle_error()
1061 wrk->lun = vm_srb->lun; in storvsc_handle_error()
1062 wrk->tgt_id = vm_srb->target_id; in storvsc_handle_error()
1073 struct vmscsi_request *vm_srb; in storvsc_command_completion() local
1081 vm_srb = &cmd_request->vstor_packet.vm_srb; in storvsc_command_completion()
1082 data_transfer_length = vm_srb->data_transfer_length; in storvsc_command_completion()
1084 scmnd->result = vm_srb->scsi_status; in storvsc_command_completion()
1096 if (vm_srb->srb_status != SRB_STATUS_SUCCESS) { in storvsc_command_completion()
1097 storvsc_handle_error(vm_srb, scmnd, host, sense_hdr.asc, in storvsc_command_completion()
1104 if (vm_srb->srb_status != SRB_STATUS_DATA_OVERRUN) in storvsc_command_completion()
1142 if ((stor_pkt->vm_srb.cdb[0] == INQUIRY) || in storvsc_on_io_completion()
1143 (stor_pkt->vm_srb.cdb[0] == MODE_SENSE)) { in storvsc_on_io_completion()
1144 vstor_packet->vm_srb.scsi_status = 0; in storvsc_on_io_completion()
1145 vstor_packet->vm_srb.srb_status = SRB_STATUS_SUCCESS; in storvsc_on_io_completion()
1150 stor_pkt->vm_srb.scsi_status = vstor_packet->vm_srb.scsi_status; in storvsc_on_io_completion()
1151 stor_pkt->vm_srb.srb_status = vstor_packet->vm_srb.srb_status; in storvsc_on_io_completion()
1154 if (vstor_packet->vm_srb.sense_info_length > sense_buffer_size) in storvsc_on_io_completion()
1155 vstor_packet->vm_srb.sense_info_length = sense_buffer_size; in storvsc_on_io_completion()
1157 stor_pkt->vm_srb.sense_info_length = in storvsc_on_io_completion()
1158 vstor_packet->vm_srb.sense_info_length; in storvsc_on_io_completion()
1160 if (vstor_packet->vm_srb.scsi_status != 0 || in storvsc_on_io_completion()
1161 vstor_packet->vm_srb.srb_status != SRB_STATUS_SUCCESS) in storvsc_on_io_completion()
1164 stor_pkt->vm_srb.cdb[0], in storvsc_on_io_completion()
1165 vstor_packet->vm_srb.scsi_status, in storvsc_on_io_completion()
1166 vstor_packet->vm_srb.srb_status); in storvsc_on_io_completion()
1168 if ((vstor_packet->vm_srb.scsi_status & 0xFF) == 0x02) { in storvsc_on_io_completion()
1170 if (vstor_packet->vm_srb.srb_status & in storvsc_on_io_completion()
1176 request, vstor_packet->vm_srb.sense_info_length); in storvsc_on_io_completion()
1179 vstor_packet->vm_srb.sense_data, in storvsc_on_io_completion()
1180 vstor_packet->vm_srb.sense_info_length); in storvsc_on_io_completion()
1185 stor_pkt->vm_srb.data_transfer_length = in storvsc_on_io_completion()
1186 vstor_packet->vm_srb.data_transfer_length; in storvsc_on_io_completion()
1463 vstor_packet->vm_srb.length = (sizeof(struct vmscsi_request) - in storvsc_do_io()
1467 vstor_packet->vm_srb.sense_info_length = sense_buffer_size; in storvsc_do_io()
1470 vstor_packet->vm_srb.data_transfer_length = in storvsc_do_io()
1588 vstor_packet->vm_srb.path_id = stor_device->path_id; in storvsc_host_reset_handler()
1662 struct vmscsi_request *vm_srb; in storvsc_queuecommand() local
1687 vm_srb = &cmd_request->vstor_packet.vm_srb; in storvsc_queuecommand()
1688 vm_srb->win8_extension.time_out_value = 60; in storvsc_queuecommand()
1690 vm_srb->win8_extension.srb_flags |= in storvsc_queuecommand()
1694 vm_srb->win8_extension.srb_flags |= in storvsc_queuecommand()
1696 vm_srb->win8_extension.queue_tag = SP_UNTAGGED; in storvsc_queuecommand()
1697 vm_srb->win8_extension.queue_action = SRB_SIMPLE_TAG_REQUEST; in storvsc_queuecommand()
1703 vm_srb->data_in = WRITE_TYPE; in storvsc_queuecommand()
1704 vm_srb->win8_extension.srb_flags |= SRB_FLAGS_DATA_OUT; in storvsc_queuecommand()
1707 vm_srb->data_in = READ_TYPE; in storvsc_queuecommand()
1708 vm_srb->win8_extension.srb_flags |= SRB_FLAGS_DATA_IN; in storvsc_queuecommand()
1711 vm_srb->data_in = UNKNOWN_TYPE; in storvsc_queuecommand()
1712 vm_srb->win8_extension.srb_flags |= SRB_FLAGS_NO_DATA_TRANSFER; in storvsc_queuecommand()
1725 vm_srb->port_number = host_dev->port; in storvsc_queuecommand()
1726 vm_srb->path_id = scmnd->device->channel; in storvsc_queuecommand()
1727 vm_srb->target_id = scmnd->device->id; in storvsc_queuecommand()
1728 vm_srb->lun = scmnd->device->lun; in storvsc_queuecommand()
1730 vm_srb->cdb_length = scmnd->cmd_len; in storvsc_queuecommand()
1732 memcpy(vm_srb->cdb, scmnd->cmnd, vm_srb->cdb_length); in storvsc_queuecommand()