Lines Matching refs:workreq
124 struct scsi_cmnd *workreq; in atp870u_intr_handle() local
332 workreq = dev->id[c][target_id].curr_req; in atp870u_intr_handle()
334 scmd_printk(KERN_DEBUG, workreq, "CDB"); in atp870u_intr_handle()
335 for (l = 0; l < workreq->cmd_len; l++) in atp870u_intr_handle()
336 printk(KERN_DEBUG " %x",workreq->cmnd[l]); in atp870u_intr_handle()
365 …if ((workreq->cmnd[0] == 0x08) || (workreq->cmnd[0] == 0x28) || (workreq->cmnd[0] == 0x0a) || (wor… in atp870u_intr_handle()
370 …if ((workreq->cmnd[0] == 0x08) || (workreq->cmnd[0] == 0x28) || (workreq->cmnd[0] == 0x0a) || (wor… in atp870u_intr_handle()
375 …if ((workreq->cmnd[0] == 0x08) || (workreq->cmnd[0] == 0x28) || (workreq->cmnd[0] == 0x0a) || (wor… in atp870u_intr_handle()
459 workreq = dev->id[c][target_id].curr_req; in atp870u_intr_handle()
466 workreq->result = atp_readb_io(dev, c, 0x0f); in atp870u_intr_handle()
469 workreq->result = 0x02; in atp870u_intr_handle()
472 workreq->result = 0x02; in atp870u_intr_handle()
481 scsi_dma_unmap(workreq); in atp870u_intr_handle()
484 (*workreq->scsi_done) (workreq); in atp870u_intr_handle()
683 struct scsi_cmnd *workreq = NULL; in DEF_SCSI_QCMD() local
703 workreq = dev->id[c][dev->last_cmd[c]].curr_req; in DEF_SCSI_QCMD()
704 if (!workreq) { in DEF_SCSI_QCMD()
712 if (!workreq) { in DEF_SCSI_QCMD()
722 workreq = dev->quereq[c][dev->quhd[c]]; in DEF_SCSI_QCMD()
723 if (dev->id[c][scmd_id(workreq)].curr_req != NULL) { in DEF_SCSI_QCMD()
729 dev->id[c][scmd_id(workreq)].curr_req = workreq; in DEF_SCSI_QCMD()
730 dev->last_cmd[c] = scmd_id(workreq); in DEF_SCSI_QCMD()
742 scmd_printk(KERN_DEBUG, workreq, "CDB"); in DEF_SCSI_QCMD()
743 for(i=0;i<workreq->cmd_len;i++) { in DEF_SCSI_QCMD()
744 printk(" %x",workreq->cmnd[i]); in DEF_SCSI_QCMD()
748 l = scsi_bufflen(workreq); in DEF_SCSI_QCMD()
753 dev->r1f[c][scmd_id(workreq)] = 0; in DEF_SCSI_QCMD()
756 if (workreq->cmnd[0] == READ_CAPACITY) { in DEF_SCSI_QCMD()
760 if (workreq->cmnd[0] == 0x00) { in DEF_SCSI_QCMD()
765 target_id = scmd_id(workreq); in DEF_SCSI_QCMD()
786 atp_writeb_io(dev, c, 0x00, workreq->cmd_len); in DEF_SCSI_QCMD()
792 for (i = 0; i < workreq->cmd_len; i++) in DEF_SCSI_QCMD()
793 atp_writeb_io(dev, c, 0x03 + i, workreq->cmnd[i]); in DEF_SCSI_QCMD()
794 atp_writeb_io(dev, c, 0x0f, workreq->device->lun); in DEF_SCSI_QCMD()
803 sg_count = scsi_dma_map(workreq); in DEF_SCSI_QCMD()
825 if (workreq->sc_data_direction == DMA_TO_DEVICE) in DEF_SCSI_QCMD()
854 scsi_for_each_sg(workreq, sgpnt, sg_count, j) { in DEF_SCSI_QCMD()
888 if ((workreq->cmnd[0] == 0x08) || (workreq->cmnd[0] == 0x28) || in DEF_SCSI_QCMD()
889 (workreq->cmnd[0] == 0x0a) || (workreq->cmnd[0] == 0x2a)) { in DEF_SCSI_QCMD()
894 …if ((workreq->cmnd[0] == 0x08) || (workreq->cmnd[0] == 0x28) || (workreq->cmnd[0] == 0x0a) || (wor… in DEF_SCSI_QCMD()
899 …if ((workreq->cmnd[0] == 0x08) || (workreq->cmnd[0] == 0x28) || (workreq->cmnd[0] == 0x0a) || (wor… in DEF_SCSI_QCMD()
905 if(workreq->sc_data_direction == DMA_TO_DEVICE) { in DEF_SCSI_QCMD()