| /linux/drivers/usb/storage/ |
| H A D | cypress_atacb.c | 77 if (likely(srb->cmnd[0] != ATA_16 && srb->cmnd[0] != ATA_12)) { in cypress_atacb_passthrough() 82 memcpy(save_cmnd, srb->cmnd, sizeof(save_cmnd)); in cypress_atacb_passthrough() 83 memset(srb->cmnd, 0, MAX_COMMAND_SIZE); in cypress_atacb_passthrough() 101 srb->cmnd[0] = 0x24; /* in cypress_atacb_passthrough() 106 srb->cmnd[1] = 0x24; /* bVSCBSubCommand : 0x24 for ATACB */ in cypress_atacb_passthrough() 108 srb->cmnd[3] = 0xff - 1; /* in cypress_atacb_passthrough() 112 srb->cmnd[4] = 1; /* TransferBlockCount : 512 */ in cypress_atacb_passthrough() 115 srb->cmnd[ 6] = save_cmnd[ 4]; /* features */ in cypress_atacb_passthrough() 116 srb->cmnd[ 7] = save_cmnd[ 6]; /* sector count */ in cypress_atacb_passthrough() 117 srb->cmnd[ 8] = save_cmnd[ 8]; /* lba low */ in cypress_atacb_passthrough() [all …]
|
| H A D | jumpshot.c | 387 pc = srb->cmnd[2] >> 6; in jumpshot_handle_mode_sense() 388 page_code = srb->cmnd[2] & 0x3F; in jumpshot_handle_mode_sense() 494 if (srb->cmnd[0] == INQUIRY) { in jumpshot_transport() 501 if (srb->cmnd[0] == READ_CAPACITY) { in jumpshot_transport() 524 if (srb->cmnd[0] == MODE_SELECT_10) { in jumpshot_transport() 529 if (srb->cmnd[0] == READ_10) { in jumpshot_transport() 530 block = ((u32)(srb->cmnd[2]) << 24) | ((u32)(srb->cmnd[3]) << 16) | in jumpshot_transport() 531 ((u32)(srb->cmnd[4]) << 8) | ((u32)(srb->cmnd[5])); in jumpshot_transport() 533 blocks = ((u32)(srb->cmnd[7]) << 8) | ((u32)(srb->cmnd[8])); in jumpshot_transport() 540 if (srb->cmnd[0] == READ_12) { in jumpshot_transport() [all …]
|
| H A D | datafab.c | 462 pc = srb->cmnd[2] >> 6; in datafab_handle_mode_sense() 463 page_code = srb->cmnd[2] & 0x3F; in datafab_handle_mode_sense() 568 if (srb->cmnd[0] == INQUIRY) { in datafab_transport() 575 if (srb->cmnd[0] == READ_CAPACITY) { in datafab_transport() 593 if (srb->cmnd[0] == MODE_SELECT_10) { in datafab_transport() 600 if (srb->cmnd[0] == READ_10) { in datafab_transport() 601 block = ((u32)(srb->cmnd[2]) << 24) | ((u32)(srb->cmnd[3]) << 16) | in datafab_transport() 602 ((u32)(srb->cmnd[4]) << 8) | ((u32)(srb->cmnd[5])); in datafab_transport() 604 blocks = ((u32)(srb->cmnd[7]) << 8) | ((u32)(srb->cmnd[8])); in datafab_transport() 611 if (srb->cmnd[0] == READ_12) { in datafab_transport() [all …]
|
| H A D | shuttle_usbat.c | 1588 data[i] = (i-7 >= srb->cmd_len) ? 0 : srb->cmnd[i-7]; in usbat_hp8200e_transport() 1595 if (srb->cmnd[0] == TEST_UNIT_READY) in usbat_hp8200e_transport() 1615 } else if (srb->cmnd[0] == READ_10 || in usbat_hp8200e_transport() 1616 srb->cmnd[0] == GPCMD_READ_CD) { in usbat_hp8200e_transport() 1643 result = usbat_write_block(us, USBAT_ATA, srb->cmnd, 12, in usbat_hp8200e_transport() 1644 srb->cmnd[0] == GPCMD_BLANK ? 75 : 10, 0); in usbat_hp8200e_transport() 1692 if (srb->cmnd[0] == INQUIRY) { in usbat_flash_transport() 1699 if (srb->cmnd[0] == READ_CAPACITY) { in usbat_flash_transport() 1723 if (srb->cmnd[0] == MODE_SELECT_10) { in usbat_flash_transport() 1728 if (srb->cmnd[ in usbat_flash_transport() [all...] |
| H A D | realtek_cr.c | 363 u8 cmnd[12] = { 0 }; in rts51x_read_mem() local 372 cmnd[0] = 0xF0; in rts51x_read_mem() 373 cmnd[1] = 0x0D; in rts51x_read_mem() 374 cmnd[2] = (u8) (addr >> 8); in rts51x_read_mem() 375 cmnd[3] = (u8) addr; in rts51x_read_mem() 376 cmnd[4] = (u8) (len >> 8); in rts51x_read_mem() 377 cmnd[5] = (u8) len; in rts51x_read_mem() 379 retval = rts51x_bulk_transport(us, 0, cmnd, 12, in rts51x_read_mem() 394 u8 cmnd[12] = { 0 }; in rts51x_write_mem() local 403 cmnd[0] = 0xF0; in rts51x_write_mem() [all …]
|
| H A D | protocol.c | 55 srb->cmnd[srb->cmd_len] = 0; in usb_stor_pad12_command() 73 srb->cmnd[srb->cmd_len] = 0; in usb_stor_ufi_command() 81 switch (srb->cmnd[0]) { in usb_stor_ufi_command() 85 srb->cmnd[4] = 36; in usb_stor_ufi_command() 90 srb->cmnd[7] = 0; in usb_stor_ufi_command() 91 srb->cmnd[8] = 8; in usb_stor_ufi_command() 96 srb->cmnd[4] = 18; in usb_stor_ufi_command()
|
| H A D | transport.c | 481 * via usb_stor_bulk_transfer_sglist() above. Set cmnd resid 565 if (srb->cmnd[0] != READ_10 && srb->cmnd[0] != WRITE_10) in last_sector_hacks() 569 sector = (srb->cmnd[2] << 24) | (srb->cmnd[3] << 16) | in last_sector_hacks() 570 (srb->cmnd[4] << 8) | (srb->cmnd[5]); in last_sector_hacks() 611 if (srb->cmnd[0] != TEST_UNIT_READY) in usb_stor_invoke_transport() 678 srb->cmnd[0] == SYNCHRONIZE_CACHE) { in usb_stor_invoke_transport() 699 if (unlikely((srb->cmnd[ in usb_stor_invoke_transport() [all...] |
| H A D | sddr55.c | 810 if (srb->cmnd[0] == REQUEST_SENSE) { in sddr55_transport() 832 if (srb->cmnd[0] == INQUIRY) { in sddr55_transport() 865 if (srb->cmnd[0] == READ_CAPACITY) { in sddr55_transport() 900 if (srb->cmnd[0] == MODE_SENSE_10) { in sddr55_transport() 906 if ( (srb->cmnd[2] & 0x3F) == 0x01 ) { in sddr55_transport() 910 } else if ( (srb->cmnd[2] & 0x3F) == 0x3F ) { in sddr55_transport() 919 if (srb->cmnd[0] == ALLOW_MEDIUM_REMOVAL) { in sddr55_transport() 922 (srb->cmnd[4]&0x03) ? "Prevent" : "Allow"); in sddr55_transport() 928 if (srb->cmnd[0] == READ_10 || srb->cmnd[0] == WRITE_10) { in sddr55_transport() 930 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in sddr55_transport() [all …]
|
| H A D | sddr09.c | 1570 if (srb->cmnd[0] == REQUEST_SENSE && havefakesense) { in sddr09_transport() 1589 if (srb->cmnd[0] == INQUIRY) { in sddr09_transport() 1595 if (srb->cmnd[0] == READ_CAPACITY) { in sddr09_transport() 1636 if (srb->cmnd[0] == MODE_SENSE_10) { in sddr09_transport() 1637 int modepage = (srb->cmnd[2] & 0x3F); in sddr09_transport() 1660 if (srb->cmnd[0] == ALLOW_MEDIUM_REMOVAL) in sddr09_transport() 1665 if (srb->cmnd[0] == READ_10) { in sddr09_transport() 1667 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in sddr09_transport() 1669 page |= short_pack(srb->cmnd[ in sddr09_transport() [all...] |
| H A D | isd200.c | 329 unsigned char cmnd[MAX_COMMAND_SIZE]; member 488 memcpy(srb->cmnd, info->cmnd, MAX_COMMAND_SIZE); in isd200_action() 555 memcpy(srb->cmnd, &ata, sizeof(ata.generic)); in isd200_action() 616 memcpy(srb->cmnd, ataCdb, sizeof(ataCdb->generic)); in isd200_invoke_transport() 660 !((srb->cmnd[0] == REQUEST_SENSE) || in isd200_invoke_transport() 661 (srb->cmnd[0] == INQUIRY) || in isd200_invoke_transport() 662 (srb->cmnd[0] == MODE_SENSE) || in isd200_invoke_transport() 663 (srb->cmnd[0] == LOG_SENSE) || in isd200_invoke_transport() 664 (srb->cmnd[0] == MODE_SENSE_10))) { in isd200_invoke_transport() 1242 switch (srb->cmnd[0]) { in isd200_scsi_to_ata() [all …]
|
| H A D | alauda.c | 1178 if (srb->cmnd[0] == INQUIRY) { in alauda_transport() 1185 if (srb->cmnd[0] == TEST_UNIT_READY) { in alauda_transport() 1190 if (srb->cmnd[0] == READ_CAPACITY) { in alauda_transport() 1212 if (srb->cmnd[0] == READ_10) { in alauda_transport() 1219 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in alauda_transport() 1221 page |= short_pack(srb->cmnd[5], srb->cmnd[4]); in alauda_transport() 1222 pages = short_pack(srb->cmnd[8], srb->cmnd[ in alauda_transport() [all...] |
| /linux/drivers/scsi/bfa/ |
| H A D | bfad_im.c | 28 struct scsi_cmnd *cmnd); 38 struct scsi_cmnd *cmnd = (struct scsi_cmnd *)dio; in bfa_cb_ioim_done() local 47 scsi_set_resid(cmnd, 0); in bfa_cb_ioim_done() 53 memcpy(cmnd->sense_buffer, sns_info, sns_len); in bfa_cb_ioim_done() 58 scsi_set_resid(cmnd, residue); in bfa_cb_ioim_done() 60 (scsi_bufflen(cmnd) - residue) < in bfa_cb_ioim_done() 61 cmnd->underflow) { in bfa_cb_ioim_done() 66 cmnd->result = host_status << 16 | scsi_status; in bfa_cb_ioim_done() 71 cmnd->result = DID_TIME_OUT << 16; in bfa_cb_ioim_done() 74 cmnd->result = DID_TRANSPORT_DISRUPTED << 16; in bfa_cb_ioim_done() [all …]
|
| /linux/drivers/scsi/ |
| H A D | sd_trace.h | 18 TP_PROTO(struct scsi_cmnd *cmnd, sector_t lba, 21 TP_ARGS(cmnd, lba, wp_offset), 33 __entry->host_no = cmnd->device->host->host_no; 34 __entry->channel = cmnd->device->channel; 35 __entry->id = cmnd->device->id; 36 __entry->lun = cmnd->device->lun; 48 TP_PROTO(struct scsi_cmnd *cmnd, sector_t rq_sector, 51 TP_ARGS(cmnd, rq_sector, wp_offset, good_bytes), 64 __entry->host_no = cmnd->device->host->host_no; 65 __entry->channel = cmnd->device->channel; [all …]
|
| H A D | scsi_error.c | 609 if (scmd->cmnd[0] == TEST_UNIT_READY && in scsi_check_sense() 907 if (scmd->cmnd[0] == TEST_UNIT_READY) 1100 * @cmnd: CDB to send. Can be NULL if no new cmnd is needed in scsi_eh_prep_cmnd() 1101 * @cmnd_size: size in bytes of @cmnd (must be <= MAX_COMMAND_SIZE) in scsi_eh_prep_cmnd() 1102 * @sense_bytes: size of sense data to copy. or 0 (if != 0 @cmnd is ignored) in scsi_eh_prep_cmnd() 1107 * @cmnd is ignored and this functions sets up a REQUEST_SENSE command in scsi_eh_prep_cmnd() 1108 * and cmnd buffers to read @sense_bytes into @scmd->sense_buffer. in scsi_eh_prep_cmnd() 1111 unsigned char *cmnd, int cmnd_size, unsigned sense_bytes) in scsi_eh_prep_cmnd() 1136 memcpy(ses->cmnd, scm in scsi_eh_prep_cmnd() 1092 scsi_eh_prep_cmnd(struct scsi_cmnd * scmd,struct scsi_eh_save * ses,unsigned char * cmnd,int cmnd_size,unsigned sense_bytes) scsi_eh_prep_cmnd() argument 1217 scsi_send_eh_cmnd(struct scsi_cmnd * scmd,unsigned char * cmnd,int cmnd_size,int timeout,unsigned sense_bytes) scsi_send_eh_cmnd() argument [all...] |
| H A D | sr.c | 401 SCpnt->cmnd[0] = WRITE_10; in sr_init_command() 405 SCpnt->cmnd[0] = READ_10; in sr_init_command() 446 SCpnt->cmnd[1] = 0; in sr_init_command() 454 put_unaligned_be32(block, &SCpnt->cmnd[2]); in sr_init_command() 455 SCpnt->cmnd[6] = SCpnt->cmnd[9] = 0; in sr_init_command() 456 put_unaligned_be16(this_count, &SCpnt->cmnd[7]); in sr_init_command() 948 scmd->cmnd[0] = GPCMD_READ_CD; in sr_read_cdda_bpc() 949 scmd->cmnd[1] = 1 << 2; in sr_read_cdda_bpc() 950 scmd->cmnd[ in sr_read_cdda_bpc() [all...] |
| H A D | 53c700.c | 566 slot->cmnd = NULL; in free_slot() 614 char *cmnd = NCR_700_get_sense_cmnd(SCp->device); in NCR_700_scsi_done() local 621 result = cmnd[7]; in NCR_700_scsi_done() 623 SCp->cmd_len = cmnd[8]; in NCR_700_scsi_done() 995 char *cmnd = in process_script_interrupt() local 1014 cmnd[0] = REQUEST_SENSE; in process_script_interrupt() 1015 cmnd[1] = (lun & 0x7) << 5; in process_script_interrupt() 1016 cmnd[2] = 0; in process_script_interrupt() 1017 cmnd[3] = 0; in process_script_interrupt() 1018 cmnd[ in process_script_interrupt() [all...] |
| H A D | megaraid.c | 496 switch (cmd->cmnd[0]) { in mega_get_ldrv_num() 630 switch (cmd->cmnd[0]) { in mega_build_cmd() 668 memset(buf, 0, cmd->cmnd[4]); in mega_build_cmd() 707 memcpy(pthru->cdb, cmd->cmnd, cmd->cmd_len); in mega_build_cmd() 747 mbox->m_out.cmd = (*cmd->cmnd & 0x02) ? in mega_build_cmd() 752 mbox->m_out.cmd = (*cmd->cmnd & 0x02) ? in mega_build_cmd() 761 mbox->m_out.numsectors = (u32) cmd->cmnd[4]; in mega_build_cmd() 763 ((u32)cmd->cmnd[1] << 16) | in mega_build_cmd() 764 ((u32)cmd->cmnd[2] << 8) | in mega_build_cmd() 765 (u32)cmd->cmnd[ in mega_build_cmd() [all...] |
| /linux/drivers/scsi/csiostor/ |
| H A D | csio_scsi.c | 174 memcpy(fcp_cmnd->fc_cdb, scmnd->cmnd, 16); in csio_scsi_fcp_cmnd() 1564 struct scsi_cmnd *cmnd = (struct scsi_cmnd *)csio_scsi_cmnd(req); in csio_scsi_err_handler() local 1572 struct csio_rnode *rn = (struct csio_rnode *)(cmnd->device->hostdata); in csio_scsi_err_handler() 1605 memcpy(cmnd->sense_buffer, in csio_scsi_err_handler() 1610 scsi_set_resid(cmnd, 0); in csio_scsi_err_handler() 1614 scsi_set_resid(cmnd, in csio_scsi_err_handler() 1619 ((scsi_bufflen(cmnd) - scsi_get_resid(cmnd)) in csio_scsi_err_handler() 1620 < cmnd->underflow)) in csio_scsi_err_handler() 1630 "Over-flow error,cmnd in csio_scsi_err_handler() 1743 struct scsi_cmnd *cmnd = (struct scsi_cmnd *)csio_scsi_cmnd(req); csio_scsi_cbfn() local 1779 csio_queuecommand(struct Scsi_Host * host,struct scsi_cmnd * cmnd) csio_queuecommand() argument 1913 csio_eh_abort_handler(struct scsi_cmnd * cmnd) csio_eh_abort_handler() argument 2019 struct scsi_cmnd *cmnd = (struct scsi_cmnd *)csio_scsi_cmnd(req); csio_tm_cbfn() local 2062 csio_eh_lun_reset_handler(struct scsi_cmnd * cmnd) csio_eh_lun_reset_handler() argument [all...] |
| /linux/drivers/scsi/aacraid/ |
| H A D | aachba.c | 1009 if (scsicmd->cmnd[2] == 0x83) { in get_container_serial_callback() 1100 sp[1] = scsicmd->cmnd[2]; in get_container_serial_callback() 1566 memcpy(hbacmd->cdb, cmd->cmnd, cmd->cmd_len); in aac_construct_hbacmd() 1591 memcpy(srbcmd->cdb, cmd->cmnd, cmd->cmd_len); in aac_scsi_64() 1622 memcpy(srbcmd->cdb, cmd->cmnd, cmd->cmd_len); in aac_scsi_32() 2333 switch (scsicmd->cmnd[0]) { in io_callback() 2336 lba = ((scsicmd->cmnd[1] & 0x1F) << 16) | in io_callback() 2337 (scsicmd->cmnd[2] << 8) | scsicmd->cmnd[3]; in io_callback() 2341 lba = ((u64)scsicmd->cmnd[2] << 56) | in io_callback() 2342 ((u64)scsicmd->cmnd[3] << 48) | in io_callback() [all …]
|
| /linux/drivers/mmc/host/ |
| H A D | vub300.c | |
| /linux/drivers/scsi/snic/ |
| H A D | snic_trc.h | 96 ((u64)sc->cmnd[0] << 56 | (u64)sc->cmnd[7] << 40 | \ 97 (u64)sc->cmnd[8] << 32 | (u64)sc->cmnd[2] << 24 | \ 98 (u64)sc->cmnd[3] << 16 | (u64)sc->cmnd[4] << 8 | \ 99 (u64)sc->cmnd[5])
|
| /linux/drivers/scsi/lpfc/ |
| H A D | lpfc_scsi.c | 553 * @cmnd: Pointer to scsi_cmnd data structure. 564 struct scsi_cmnd *cmnd) in lpfc_get_scsi_buf_s3() argument 594 * @cmnd: Pointer to scsi_cmnd data structure. 605 struct scsi_cmnd *cmnd) in lpfc_get_scsi_buf_s4() argument 617 if (cmnd && phba->cfg_fcp_io_sched == LPFC_FCP_SCHED_BY_HDWQ) { in lpfc_get_scsi_buf_s4() 618 tag = blk_mq_unique_tag(scsi_cmd_to_rq(cmnd)); in lpfc_get_scsi_buf_s4() 665 if (cmnd && cmnd->cmd_len > LPFC_FCP_CDB_LEN) in lpfc_get_scsi_buf_s4() 689 * @cmnd: Pointer to scsi_cmnd data structure. 700 struct scsi_cmnd *cmnd) in lpfc_get_scsi_buf() argument 3571 struct scsi_cmnd *cmnd = lpfc_cmd->pCmd; lpfc_send_scsi_error_event() local 3829 struct scsi_cmnd *cmnd = lpfc_cmd->pCmd; lpfc_handle_fcp_err() local 5217 lpfc_queuecommand(struct Scsi_Host * shost,struct scsi_cmnd * cmnd) lpfc_queuecommand() argument 5503 lpfc_abort_handler(struct scsi_cmnd * cmnd) lpfc_abort_handler() argument 5973 lpfc_device_reset_handler(struct scsi_cmnd * cmnd) lpfc_device_reset_handler() argument 6051 lpfc_target_reset_handler(struct scsi_cmnd * cmnd) lpfc_target_reset_handler() argument 6183 lpfc_host_reset_handler(struct scsi_cmnd * cmnd) lpfc_host_reset_handler() argument 6727 lpfc_no_command(struct Scsi_Host * shost,struct scsi_cmnd * cmnd) lpfc_no_command() argument [all...] |
| /linux/drivers/scsi/elx/efct/ |
| H A D | efct_unsol.c | 159 efct_populate_io_fcp_cmd(struct efct_io *io, struct fcp_cmnd *cmnd, in efct_populate_io_fcp_cmd() argument 164 io->exp_xfer_len = be32_to_cpu(cmnd->fc_dl); in efct_populate_io_fcp_cmd() 181 efct_get_flags_fcp_cmd(struct fcp_cmnd *cmnd) in efct_get_flags_fcp_cmd() argument 185 switch (cmnd->fc_pri_ta & FCP_PTA_MASK) { in efct_get_flags_fcp_cmd() 199 if (cmnd->fc_flags & FCP_CFL_WRDATA) in efct_get_flags_fcp_cmd() 201 if (cmnd->fc_flags & FCP_CFL_RDDATA) in efct_get_flags_fcp_cmd() 343 struct fcp_cmnd *cmnd = NULL; in efct_dispatch_fcp_cmd() local 352 cmnd = seq->payload->dma.virt; in efct_dispatch_fcp_cmd() 358 lun = scsilun_to_int(&cmnd->fc_lun); in efct_dispatch_fcp_cmd() 379 efct_populate_io_fcp_cmd(io, cmnd, fchdr, true); in efct_dispatch_fcp_cmd() [all …]
|
| /linux/drivers/usb/gadget/function/ |
| H A D | f_mass_storage.c | 257 u8 cmnd[MAX_COMMAND_SIZE]; member 626 if (common->cmnd[0] == READ_6) in do_read() 627 lba = get_unaligned_be24(&common->cmnd[1]); in do_read() 629 if (common->cmnd[0] == READ_16) in do_read() 630 lba = get_unaligned_be64(&common->cmnd[2]); in do_read() 632 lba = get_unaligned_be32(&common->cmnd[2]); in do_read() 639 if ((common->cmnd[1] & ~0x18) != 0) { in do_read() 766 if (common->cmnd[0] == WRITE_6) in do_write() 767 lba = get_unaligned_be24(&common->cmnd[1]); in do_write() 769 if (common->cmnd[ in do_write() [all...] |
| /linux/drivers/scsi/ibmvscsi/ |
| H A D | ibmvscsi.c | 587 evt_struct->cmnd = NULL; in init_event_struct() 649 if (evt_struct->cmnd) in unmap_cmd_data() 650 scsi_dma_unmap(evt_struct->cmnd); in unmap_cmd_data() 795 if (evt->cmnd) { in purge_requests() 796 evt->cmnd->result = (error_code << 16); in purge_requests() 800 evt->cmnd_done(evt->cmnd); in purge_requests() 980 if (evt_struct->cmnd != NULL) { in ibmvscsi_send_srp_event() 981 evt_struct->cmnd->result = DID_ERROR << 16; in ibmvscsi_send_srp_event() 982 evt_struct->cmnd_done(evt_struct->cmnd); in ibmvscsi_send_srp_event() 1000 struct scsi_cmnd *cmnd in handle_cmd_rsp() local 1044 ibmvscsi_queuecommand_lck(struct scsi_cmnd * cmnd) ibmvscsi_queuecommand_lck() argument [all...] |