Lines Matching refs:uscsi
2727 struct uscsi_cmd *uscsi = (struct uscsi_cmd *)ioctl_arg; in vd_scsicmd_in() local
2742 uscsi->uscsi_flags = vd_scsi_debug; in vd_scsicmd_in()
2745 uscsi->uscsi_flags |= USCSI_ISOLATE; in vd_scsicmd_in()
2746 uscsi->uscsi_flags |= USCSI_DIAGNOSE; in vd_scsicmd_in()
2752 uscsi->uscsi_flags |= USCSI_HEAD; in vd_scsicmd_in()
2755 uscsi->uscsi_flags |= USCSI_HTAG; in vd_scsicmd_in()
2758 uscsi->uscsi_flags |= USCSI_OTAG; in vd_scsicmd_in()
2761 uscsi->uscsi_flags |= USCSI_NOTAG; in vd_scsicmd_in()
2766 uscsi->uscsi_timeout = vd_scsi->timeout; in vd_scsicmd_in()
2769 uscsi->uscsi_cdb = (caddr_t)VD_SCSI_DATA_CDB(vd_scsi); in vd_scsicmd_in()
2770 uscsi->uscsi_cdblen = vd_scsi->cdb_len; in vd_scsicmd_in()
2774 uscsi->uscsi_flags |= USCSI_RQENABLE; in vd_scsicmd_in()
2775 uscsi->uscsi_rqbuf = (caddr_t)VD_SCSI_DATA_SENSE(vd_scsi); in vd_scsicmd_in()
2776 uscsi->uscsi_rqlen = vd_scsi->sense_len; in vd_scsicmd_in()
2786 uscsi->uscsi_flags |= USCSI_READ; in vd_scsicmd_in()
2787 uscsi->uscsi_buflen = vd_scsi->datain_len; in vd_scsicmd_in()
2788 uscsi->uscsi_bufaddr = (char *)VD_SCSI_DATA_IN(vd_scsi); in vd_scsicmd_in()
2793 uscsi->uscsi_buflen = vd_scsi->dataout_len; in vd_scsicmd_in()
2794 uscsi->uscsi_bufaddr = (char *)VD_SCSI_DATA_OUT(vd_scsi); in vd_scsicmd_in()
2804 struct uscsi_cmd *uscsi = (struct uscsi_cmd *)ioctl_arg; in vd_scsicmd_out() local
2807 vd_scsi->cmd_status = uscsi->uscsi_status; in vd_scsicmd_out()
2810 if ((uscsi->uscsi_flags & USCSI_RQENABLE) && in vd_scsicmd_out()
2811 (uscsi->uscsi_status == STATUS_CHECK || in vd_scsicmd_out()
2812 uscsi->uscsi_status == STATUS_TERMINATED)) { in vd_scsicmd_out()
2813 vd_scsi->sense_status = uscsi->uscsi_rqstatus; in vd_scsicmd_out()
2814 if (uscsi->uscsi_rqstatus == STATUS_GOOD) in vd_scsicmd_out()
2815 vd_scsi->sense_len -= uscsi->uscsi_rqresid; in vd_scsicmd_out()
2822 if (uscsi->uscsi_status != STATUS_GOOD) { in vd_scsicmd_out()
2828 if (uscsi->uscsi_flags & USCSI_READ) { in vd_scsicmd_out()
2830 vd_scsi->datain_len -= uscsi->uscsi_resid; in vd_scsicmd_out()
2835 vd_scsi->dataout_len -= uscsi->uscsi_resid; in vd_scsicmd_out()
3517 struct uscsi_cmd *uscsi = (struct uscsi_cmd *)ioctl->arg; in vd_do_ioctl() local
3521 !(uscsi->uscsi_flags & USCSI_READ)) { in vd_do_ioctl()
3610 struct uscsi_cmd uscsi = {0}; in vd_ioctl() local
3651 &uscsi, vd_scsicmd_in, vd_scsicmd_out, B_FALSE}, in vd_ioctl()
3793 struct uscsi_cmd uscsi = { 0 }; in vd_scsi_reset() local
3795 uscsi.uscsi_flags = vd_scsi_debug | USCSI_RESET; in vd_scsi_reset()
3796 uscsi.uscsi_timeout = vd_scsi_rdwr_timeout; in vd_scsi_reset()
3798 status = ldi_ioctl(vd->ldi_handle[0], USCSICMD, (intptr_t)&uscsi, in vd_scsi_reset()