Home
last modified time | relevance | path

Searched refs:cmnd (Results 1 – 25 of 123) sorted by relevance

12345

/drivers/usb/storage/
Dcypress_atacb.c43 if (likely(srb->cmnd[0] != ATA_16 && srb->cmnd[0] != ATA_12)) { in cypress_atacb_passthrough()
48 memcpy(save_cmnd, srb->cmnd, sizeof(save_cmnd)); in cypress_atacb_passthrough()
49 memset(srb->cmnd, 0, MAX_COMMAND_SIZE); in cypress_atacb_passthrough()
67 srb->cmnd[0] = 0x24; /* bVSCBSignature : vendor-specific command in cypress_atacb_passthrough()
70 srb->cmnd[1] = 0x24; /* bVSCBSubCommand : 0x24 for ATACB */ in cypress_atacb_passthrough()
72 srb->cmnd[3] = 0xff - 1; /* features, sector count, lba low, lba med in cypress_atacb_passthrough()
74 srb->cmnd[4] = 1; /* TransferBlockCount : 512 */ in cypress_atacb_passthrough()
77 srb->cmnd[ 6] = save_cmnd[ 4]; /* features */ in cypress_atacb_passthrough()
78 srb->cmnd[ 7] = save_cmnd[ 6]; /* sector count */ in cypress_atacb_passthrough()
79 srb->cmnd[ 8] = save_cmnd[ 8]; /* lba low */ in cypress_atacb_passthrough()
[all …]
Djumpshot.c345 pc = srb->cmnd[2] >> 6; in jumpshot_handle_mode_sense()
346 page_code = srb->cmnd[2] & 0x3F; in jumpshot_handle_mode_sense()
453 if (srb->cmnd[0] == INQUIRY) { in jumpshot_transport()
460 if (srb->cmnd[0] == READ_CAPACITY) { in jumpshot_transport()
483 if (srb->cmnd[0] == MODE_SELECT_10) { in jumpshot_transport()
488 if (srb->cmnd[0] == READ_10) { in jumpshot_transport()
489 block = ((u32)(srb->cmnd[2]) << 24) | ((u32)(srb->cmnd[3]) << 16) | in jumpshot_transport()
490 ((u32)(srb->cmnd[4]) << 8) | ((u32)(srb->cmnd[5])); in jumpshot_transport()
492 blocks = ((u32)(srb->cmnd[7]) << 8) | ((u32)(srb->cmnd[8])); in jumpshot_transport()
498 if (srb->cmnd[0] == READ_12) { in jumpshot_transport()
[all …]
Ddatafab.c418 pc = srb->cmnd[2] >> 6; in datafab_handle_mode_sense()
419 page_code = srb->cmnd[2] & 0x3F; in datafab_handle_mode_sense()
526 if (srb->cmnd[0] == INQUIRY) { in datafab_transport()
533 if (srb->cmnd[0] == READ_CAPACITY) { in datafab_transport()
551 if (srb->cmnd[0] == MODE_SELECT_10) { in datafab_transport()
558 if (srb->cmnd[0] == READ_10) { in datafab_transport()
559 block = ((u32)(srb->cmnd[2]) << 24) | ((u32)(srb->cmnd[3]) << 16) | in datafab_transport()
560 ((u32)(srb->cmnd[4]) << 8) | ((u32)(srb->cmnd[5])); in datafab_transport()
562 blocks = ((u32)(srb->cmnd[7]) << 8) | ((u32)(srb->cmnd[8])); in datafab_transport()
568 if (srb->cmnd[0] == READ_12) { in datafab_transport()
[all …]
Dshuttle_usbat.c1455 data[i] = (i-7 >= srb->cmd_len) ? 0 : srb->cmnd[i-7]; in usbat_hp8200e_transport()
1462 if (srb->cmnd[0] == TEST_UNIT_READY) in usbat_hp8200e_transport()
1482 } else if (srb->cmnd[0] == READ_10 || in usbat_hp8200e_transport()
1483 srb->cmnd[0] == GPCMD_READ_CD) { in usbat_hp8200e_transport()
1511 USBAT_ATA, srb->cmnd, 12, in usbat_hp8200e_transport()
1512 (srb->cmnd[0]==GPCMD_BLANK ? 75 : 10), 0) != in usbat_hp8200e_transport()
1560 if (srb->cmnd[0] == INQUIRY) { in usbat_flash_transport()
1567 if (srb->cmnd[0] == READ_CAPACITY) { in usbat_flash_transport()
1593 if (srb->cmnd[0] == MODE_SELECT_10) { in usbat_flash_transport()
1598 if (srb->cmnd[0] == READ_10) { in usbat_flash_transport()
[all …]
Dprotocol.c67 srb->cmnd[srb->cmd_len] = 0; in usb_stor_pad12_command()
87 srb->cmnd[srb->cmd_len] = 0; in usb_stor_ufi_command()
95 switch (srb->cmnd[0]) { in usb_stor_ufi_command()
99 srb->cmnd[4] = 36; in usb_stor_ufi_command()
104 srb->cmnd[7] = 0; in usb_stor_ufi_command()
105 srb->cmnd[8] = 8; in usb_stor_ufi_command()
110 srb->cmnd[4] = 18; in usb_stor_ufi_command()
Dsddr55.c765 if (srb->cmnd[0] == REQUEST_SENSE) { in sddr55_transport()
782 if (srb->cmnd[0] == INQUIRY) { in sddr55_transport()
812 if (srb->cmnd[0] == READ_CAPACITY) { in sddr55_transport()
843 if (srb->cmnd[0] == MODE_SENSE_10) { in sddr55_transport()
849 if ( (srb->cmnd[2] & 0x3F) == 0x01 ) { in sddr55_transport()
854 } else if ( (srb->cmnd[2] & 0x3F) == 0x3F ) { in sddr55_transport()
864 if (srb->cmnd[0] == ALLOW_MEDIUM_REMOVAL) { in sddr55_transport()
869 (srb->cmnd[4]&0x03) ? "Prevent" : "Allow"); in sddr55_transport()
875 if (srb->cmnd[0] == READ_10 || srb->cmnd[0] == WRITE_10) { in sddr55_transport()
877 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in sddr55_transport()
[all …]
Dtransport.c544 if (srb->cmnd[0] != READ_10 && srb->cmnd[0] != WRITE_10) in last_sector_hacks()
548 sector = (srb->cmnd[2] << 24) | (srb->cmnd[3] << 16) | in last_sector_hacks()
549 (srb->cmnd[4] << 8) | (srb->cmnd[5]); in last_sector_hacks()
587 if (srb->cmnd[0] != TEST_UNIT_READY) in last_sector_hacks()
665 if ((srb->cmnd[0] == ATA_16 || srb->cmnd[0] == ATA_12) && in usb_stor_invoke_transport()
668 !(srb->cmnd[2] & 0x20)) { in usb_stor_invoke_transport()
678 !((srb->cmnd[0] == REQUEST_SENSE) || in usb_stor_invoke_transport()
679 (srb->cmnd[0] == INQUIRY) || in usb_stor_invoke_transport()
680 (srb->cmnd[0] == MODE_SENSE) || in usb_stor_invoke_transport()
681 (srb->cmnd[0] == LOG_SENSE) || in usb_stor_invoke_transport()
[all …]
Dsddr09.c1518 if (srb->cmnd[0] == REQUEST_SENSE && havefakesense) { in sddr09_transport()
1535 if (srb->cmnd[0] == INQUIRY) { in sddr09_transport()
1541 if (srb->cmnd[0] == READ_CAPACITY) { in sddr09_transport()
1582 if (srb->cmnd[0] == MODE_SENSE_10) { in sddr09_transport()
1583 int modepage = (srb->cmnd[2] & 0x3F); in sddr09_transport()
1604 if (srb->cmnd[0] == ALLOW_MEDIUM_REMOVAL) in sddr09_transport()
1609 if (srb->cmnd[0] == READ_10) { in sddr09_transport()
1611 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in sddr09_transport()
1613 page |= short_pack(srb->cmnd[5], srb->cmnd[4]); in sddr09_transport()
1614 pages = short_pack(srb->cmnd[8], srb->cmnd[7]); in sddr09_transport()
[all …]
Dalauda.c1025 if (srb->cmnd[0] == INQUIRY) { in alauda_transport()
1033 if (srb->cmnd[0] == TEST_UNIT_READY) { in alauda_transport()
1038 if (srb->cmnd[0] == READ_CAPACITY) { in alauda_transport()
1060 if (srb->cmnd[0] == READ_10) { in alauda_transport()
1067 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in alauda_transport()
1069 page |= short_pack(srb->cmnd[5], srb->cmnd[4]); in alauda_transport()
1070 pages = short_pack(srb->cmnd[8], srb->cmnd[7]); in alauda_transport()
1078 if (srb->cmnd[0] == WRITE_10) { in alauda_transport()
1085 page = short_pack(srb->cmnd[3], srb->cmnd[2]); in alauda_transport()
1087 page |= short_pack(srb->cmnd[5], srb->cmnd[4]); in alauda_transport()
[all …]
Disd200.c293 unsigned char cmnd[BLK_MAX_CDB]; member
452 srb->cmnd = info->cmnd; in isd200_action()
520 memcpy(srb->cmnd, &ata, sizeof(ata.generic)); in isd200_action()
580 memcpy(srb->cmnd, ataCdb, sizeof(ataCdb->generic)); in isd200_invoke_transport()
623 !((srb->cmnd[0] == REQUEST_SENSE) || in isd200_invoke_transport()
624 (srb->cmnd[0] == INQUIRY) || in isd200_invoke_transport()
625 (srb->cmnd[0] == MODE_SENSE) || in isd200_invoke_transport()
626 (srb->cmnd[0] == LOG_SENSE) || in isd200_invoke_transport()
627 (srb->cmnd[0] == MODE_SENSE_10))) { in isd200_invoke_transport()
1268 switch (srb->cmnd[0]) { in isd200_scsi_to_ata()
[all …]
/drivers/scsi/lpfc/
Dlpfc_scsi.c62 lpfc_debug_save_data(struct scsi_cmnd *cmnd) in lpfc_debug_save_data() argument
65 struct scatterlist *sgde = scsi_sglist(cmnd); in lpfc_debug_save_data()
89 lpfc_debug_save_dif(struct scsi_cmnd *cmnd) in lpfc_debug_save_dif() argument
92 struct scatterlist *sgde = scsi_prot_sglist(cmnd); in lpfc_debug_save_dif()
1318 cmd->cmnd[0], (unsigned long long)scsi_get_lba(cmd), in lpfc_parse_bg_err()
1324 (cmd->cmnd[7] << 8 | cmd->cmnd[8])); in lpfc_parse_bg_err()
1331 (cmd->cmnd[7] << 8 | cmd->cmnd[8])); in lpfc_parse_bg_err()
1428 struct scsi_cmnd *cmnd = lpfc_cmd->pCmd; in lpfc_send_scsi_error_event() local
1438 if ((cmnd->result == SAM_STAT_TASK_SET_FULL) || in lpfc_send_scsi_error_event()
1439 (cmnd->result == SAM_STAT_BUSY)) { in lpfc_send_scsi_error_event()
[all …]
/drivers/scsi/aacraid/
Daachba.c799 sp[1] = scsicmd->cmnd[2]; in get_container_serial_callback()
1162 memcpy(srbcmd->cdb, cmd->cmnd, cmd->cmd_len); in aac_scsi_64()
1190 memcpy(srbcmd->cdb, cmd->cmnd, cmd->cmd_len); in aac_scsi_32()
1479 switch (scsicmd->cmnd[0]) { in io_callback()
1482 lba = ((scsicmd->cmnd[1] & 0x1F) << 16) | in io_callback()
1483 (scsicmd->cmnd[2] << 8) | scsicmd->cmnd[3]; in io_callback()
1487 lba = ((u64)scsicmd->cmnd[2] << 56) | in io_callback()
1488 ((u64)scsicmd->cmnd[3] << 48) | in io_callback()
1489 ((u64)scsicmd->cmnd[4] << 40) | in io_callback()
1490 ((u64)scsicmd->cmnd[5] << 32) | in io_callback()
[all …]
/drivers/scsi/
Dscsi_error.c581 unsigned char *cmnd, int cmnd_size, unsigned sense_bytes) in scsi_eh_prep_cmnd() argument
593 ses->cmnd = scmd->cmnd; in scsi_eh_prep_cmnd()
602 scmd->cmnd = ses->eh_cmnd; in scsi_eh_prep_cmnd()
603 memset(scmd->cmnd, 0, BLK_MAX_CDB); in scsi_eh_prep_cmnd()
615 scmd->cmnd[0] = REQUEST_SENSE; in scsi_eh_prep_cmnd()
616 scmd->cmnd[4] = scmd->sdb.length; in scsi_eh_prep_cmnd()
617 scmd->cmd_len = COMMAND_SIZE(scmd->cmnd[0]); in scsi_eh_prep_cmnd()
620 if (cmnd) { in scsi_eh_prep_cmnd()
622 memcpy(scmd->cmnd, cmnd, cmnd_size); in scsi_eh_prep_cmnd()
623 scmd->cmd_len = COMMAND_SIZE(scmd->cmnd[0]); in scsi_eh_prep_cmnd()
[all …]
Dsd.c498 SCpnt->cmnd[0] = WRITE_6; in sd_prep_fn()
506 SCpnt->cmnd[0] = READ_6; in sd_prep_fn()
522 SCpnt->cmnd[1] = 1 << 5; in sd_prep_fn()
524 SCpnt->cmnd[1] = 0; in sd_prep_fn()
527 SCpnt->cmnd[0] += READ_16 - READ_6; in sd_prep_fn()
528 SCpnt->cmnd[1] |= blk_fua_rq(rq) ? 0x8 : 0; in sd_prep_fn()
529 SCpnt->cmnd[2] = sizeof(block) > 4 ? (unsigned char) (block >> 56) & 0xff : 0; in sd_prep_fn()
530 SCpnt->cmnd[3] = sizeof(block) > 4 ? (unsigned char) (block >> 48) & 0xff : 0; in sd_prep_fn()
531 SCpnt->cmnd[4] = sizeof(block) > 4 ? (unsigned char) (block >> 40) & 0xff : 0; in sd_prep_fn()
532 SCpnt->cmnd[5] = sizeof(block) > 4 ? (unsigned char) (block >> 32) & 0xff : 0; in sd_prep_fn()
[all …]
Dps3rom.c98 unsigned char opcode = cmd->cmnd[0]; in ps3rom_atapi_request()
106 memcpy(&atapi_cmnd.pkt, cmd->cmnd, 12); in ps3rom_atapi_request()
160 return cmd->cmnd[2] << 24 | cmd->cmnd[3] << 16 | cmd->cmnd[4] << 8 | in srb10_lba()
161 cmd->cmnd[5]; in srb10_lba()
166 return cmd->cmnd[7] << 8 | cmd->cmnd[8]; in srb10_len()
228 opcode = cmd->cmnd[0]; in ps3rom_queuecommand()
321 if (cmd->cmnd[0] == REQUEST_SENSE) { in ps3rom_interrupt()
Dgdth.c443 int __gdth_execute(struct scsi_device *sdev, gdth_cmd_str *gdtcmd, char *cmnd, in __gdth_execute() argument
468 scp->cmnd = cmnd; in __gdth_execute()
473 TRACE(("__gdth_execute() cmd 0x%x\n", scp->cmnd[0])); in __gdth_execute()
486 int gdth_execute(struct Scsi_Host *shost, gdth_cmd_str *gdtcmd, char *cmnd, in gdth_execute() argument
490 int rval = __gdth_execute(sdev, gdtcmd, cmnd, timeout, info); in gdth_execute()
1329 if (ha->cmd_tab[i].cmnd == UNUSED_CMND) { in gdth_get_cmd_index()
1330 ha->cmd_tab[i].cmnd = ha->pccb->RequestBuffer; in gdth_get_cmd_index()
1425 if (ha->cmd_tab[j].cmnd != UNUSED_CMND) in gdth_release_event()
2081 if (nscp->cmnd[0] == TEST_UNIT_READY) { in gdth_next()
2113 if (b == ha->virt_bus && nscp->cmnd[0] != INQUIRY && in gdth_next()
[all …]
Dinitio.c713 static void initio_release_scb(struct initio_host * host, struct scsi_ctrl_blk * cmnd) in initio_release_scb() argument
718 printk("Release SCB %p; ", cmnd); in initio_release_scb()
721 cmnd->srb = NULL; in initio_release_scb()
722 cmnd->status = 0; in initio_release_scb()
723 cmnd->next = NULL; in initio_release_scb()
725 host->last_avail->next = cmnd; in initio_release_scb()
726 host->last_avail = cmnd; in initio_release_scb()
728 host->first_avail = cmnd; in initio_release_scb()
729 host->last_avail = cmnd; in initio_release_scb()
2562 …d initio_build_scb(struct initio_host * host, struct scsi_ctrl_blk * cblk, struct scsi_cmnd * cmnd) in initio_build_scb() argument
[all …]
D53c700.c556 slot->cmnd = NULL; in free_slot()
604 char *cmnd = NCR_700_get_sense_cmnd(SCp->device); in NCR_700_scsi_done() local
607 SCp, SCp->cmnd[7], result); in NCR_700_scsi_done()
616 result = cmnd[7]; in NCR_700_scsi_done()
618 SCp->cmd_len = cmnd[8]; in NCR_700_scsi_done()
991 char *cmnd = in process_script_interrupt() local
1010 cmnd[0] = REQUEST_SENSE; in process_script_interrupt()
1011 cmnd[1] = (SCp->device->lun & 0x7) << 5; in process_script_interrupt()
1012 cmnd[2] = 0; in process_script_interrupt()
1013 cmnd[3] = 0; in process_script_interrupt()
[all …]
Dmegaraid.c485 switch (cmd->cmnd[0]) { in mega_get_ldrv_num()
527 if((cmd->cmnd[0] == MEGA_INTERNAL_CMD)) in mega_build_cmd()
626 switch (cmd->cmnd[0]) { in mega_build_cmd()
664 memset(buf, 0, cmd->cmnd[4]); in mega_build_cmd()
703 memcpy(pthru->cdb, cmd->cmnd, cmd->cmd_len); in mega_build_cmd()
743 mbox->m_out.cmd = (*cmd->cmnd & 0x02) ? in mega_build_cmd()
748 mbox->m_out.cmd = (*cmd->cmnd & 0x02) ? in mega_build_cmd()
757 mbox->m_out.numsectors = (u32) cmd->cmnd[4]; in mega_build_cmd()
759 ((u32)cmd->cmnd[1] << 16) | in mega_build_cmd()
760 ((u32)cmd->cmnd[2] << 8) | in mega_build_cmd()
[all …]
/drivers/scsi/ibmvscsi/
Dibmvscsi.c270 evt_struct->cmnd = NULL; in init_event_struct()
496 if (tmp_evt->cmnd) { in purge_requests()
497 tmp_evt->cmnd->result = (error_code << 16); in purge_requests()
502 tmp_evt->cmnd_done(tmp_evt->cmnd); in purge_requests()
665 if (evt_struct->cmnd != NULL) { in ibmvscsi_send_srp_event()
666 evt_struct->cmnd->result = DID_ERROR << 16; in ibmvscsi_send_srp_event()
667 evt_struct->cmnd_done(evt_struct->cmnd); in ibmvscsi_send_srp_event()
685 struct scsi_cmnd *cmnd = evt_struct->cmnd; in handle_cmd_rsp() local
693 if (cmnd) { in handle_cmd_rsp()
694 cmnd->result |= rsp->status; in handle_cmd_rsp()
[all …]
Dibmvfc.c756 struct scsi_cmnd *cmnd = evt->cmnd; in ibmvfc_scsi_eh_done() local
758 if (cmnd) { in ibmvfc_scsi_eh_done()
759 scsi_dma_unmap(cmnd); in ibmvfc_scsi_eh_done()
760 cmnd->scsi_done(cmnd); in ibmvfc_scsi_eh_done()
779 if (evt->cmnd) { in ibmvfc_fail_request()
780 evt->cmnd->result = (error_code << 16); in ibmvfc_fail_request()
1250 evt->cmnd = NULL; in ibmvfc_init_event()
1400 if (evt->cmnd) in ibmvfc_send_event()
1401 scsi_dma_unmap(evt->cmnd); in ibmvfc_send_event()
1407 if (evt->cmnd) { in ibmvfc_send_event()
[all …]
/drivers/usb/gadget/
Df_mass_storage.c347 u8 cmnd[MAX_COMMAND_SIZE]; member
427 16, 1, fsg->cmnd, fsg->cmnd_size, 0); in dump_cdb()
777 if (fsg->cmnd[0] == SC_READ_6) in do_read()
778 lba = (fsg->cmnd[1] << 16) | get_be16(&fsg->cmnd[2]); in do_read()
780 lba = get_be32(&fsg->cmnd[2]); in do_read()
785 if ((fsg->cmnd[1] & ~0x18) != 0) { in do_read()
910 if (fsg->cmnd[0] == SC_WRITE_6) in do_write()
911 lba = (fsg->cmnd[1] << 16) | get_be16(&fsg->cmnd[2]); in do_write()
913 lba = get_be32(&fsg->cmnd[2]); in do_write()
919 if ((fsg->cmnd[1] & ~0x18) != 0) { in do_write()
[all …]
Dfile_storage.c695 u8 cmnd[MAX_COMMAND_SIZE]; member
772 16, 1, fsg->cmnd, fsg->cmnd_size, 0); in dump_cdb()
1585 if (fsg->cmnd[0] == SC_READ_6) in do_read()
1586 lba = (fsg->cmnd[1] << 16) | get_be16(&fsg->cmnd[2]); in do_read()
1588 lba = get_be32(&fsg->cmnd[2]); in do_read()
1593 if ((fsg->cmnd[1] & ~0x18) != 0) { in do_read()
1718 if (fsg->cmnd[0] == SC_WRITE_6) in do_write()
1719 lba = (fsg->cmnd[1] << 16) | get_be16(&fsg->cmnd[2]); in do_write()
1721 lba = get_be32(&fsg->cmnd[2]); in do_write()
1727 if ((fsg->cmnd[1] & ~0x18) != 0) { in do_write()
[all …]
/drivers/usb/image/
Dmicrotek.c230 switch (srb->cmnd[0]) { in mts_show_command()
304 srb->cmnd[0], srb->cmnd[1], srb->cmnd[2], srb->cmnd[3], srb->cmnd[4], srb->cmnd[5], in mts_show_command()
305 srb->cmnd[6], srb->cmnd[7], srb->cmnd[8], srb->cmnd[9]); in mts_show_command()
482 if (context->srb->cmnd[0] == REQUEST_SENSE) { in mts_command_done()
567 if ( !memcmp( srb->cmnd, mts_read_image_sig, mts_read_image_sig_len ) in mts_build_transfer_context()
571 } else if ( MTS_DIRECTION_IS_IN(srb->cmnd[0]) ) { in mts_build_transfer_context()
613 srb->cmnd, in mts_scsi_queuecommand()
/drivers/scsi/megaraid/
Dmegaraid_sas.c687 memcpy(pthru->cdb, scp->cmnd, scp->cmd_len); in megasas_build_dcdb()
730 u8 sc = scp->cmnd[0]; in megasas_build_ldio()
754 ldio->access_byte = (scp->cmd_len != 6) ? scp->cmnd[1] : 0; in megasas_build_ldio()
760 ldio->lba_count = (u32) scp->cmnd[4]; in megasas_build_ldio()
761 ldio->start_lba_lo = ((u32) scp->cmnd[1] << 16) | in megasas_build_ldio()
762 ((u32) scp->cmnd[2] << 8) | (u32) scp->cmnd[3]; in megasas_build_ldio()
771 ldio->lba_count = (u32) scp->cmnd[8] | in megasas_build_ldio()
772 ((u32) scp->cmnd[7] << 8); in megasas_build_ldio()
773 ldio->start_lba_lo = ((u32) scp->cmnd[2] << 24) | in megasas_build_ldio()
774 ((u32) scp->cmnd[3] << 16) | in megasas_build_ldio()
[all …]

12345