Home
last modified time | relevance | path

Searched refs:cdb (Results 1 – 25 of 167) sorted by relevance

1234567

/linux-6.6.21/drivers/scsi/
Dscsi_trace.c11 #define SERVICE_ACTION16(cdb) (cdb[1] & 0x1f) argument
12 #define SERVICE_ACTION32(cdb) (get_unaligned_be16(&cdb[8])) argument
18 scsi_trace_rw6(struct trace_seq *p, unsigned char *cdb, int len) in scsi_trace_rw6() argument
23 lba = get_unaligned_be24(&cdb[1]) & 0x1fffff; in scsi_trace_rw6()
28 txlen = cdb[4] ? cdb[4] : 256; in scsi_trace_rw6()
37 scsi_trace_rw10(struct trace_seq *p, unsigned char *cdb, int len) in scsi_trace_rw10() argument
42 lba = get_unaligned_be32(&cdb[2]); in scsi_trace_rw10()
43 txlen = get_unaligned_be16(&cdb[7]); in scsi_trace_rw10()
46 cdb[1] >> 5); in scsi_trace_rw10()
48 if (cdb[0] == WRITE_SAME) in scsi_trace_rw10()
[all …]
Dpmcraid.c313 memset(&cmd->ioa_cb->ioarcb.cdb, 0, PMCRAID_MAX_CDB_LEN); in pmcraid_init_cmdblk()
691 cmd->ioa_cb->ioarcb.cdb[0]); in pmcraid_timeout_handler()
759 cmd->ioa_cb->ioarcb.cdb[0], in pmcraid_internal_done()
797 cmd->ioa_cb->ioarcb.cdb[0], in pmcraid_reinit_cfgtable_done()
828 cmd->ioa_cb->ioarcb.cdb[0], ioasc); in pmcraid_erp_done()
937 cmd->ioa_cb->ioarcb.cdb[0], in pmcraid_ioa_shutdown()
947 cmd->ioa_cb->ioarcb.cdb[0] = PMCRAID_IOA_SHUTDOWN; in pmcraid_ioa_shutdown()
948 cmd->ioa_cb->ioarcb.cdb[1] = PMCRAID_SHUTDOWN_NORMAL; in pmcraid_ioa_shutdown()
1009 ioarcb->cdb[0] = INQUIRY; in pmcraid_get_fwversion()
1010 ioarcb->cdb[1] = 1; in pmcraid_get_fwversion()
[all …]
Dipr.c595 trace_entry->op_code = ipr_cmd->ioarcb.cmd_pkt.cdb[0]; in ipr_trc_hook()
1071 ioarcb->cmd_pkt.cdb[0] = IPR_HOST_CONTROLLED_ASYNC; in ipr_send_hcam()
1072 ioarcb->cmd_pkt.cdb[1] = type; in ipr_send_hcam()
1073 ioarcb->cmd_pkt.cdb[7] = (sizeof(hostrcb->hcam) >> 8) & 0xff; in ipr_send_hcam()
1074 ioarcb->cmd_pkt.cdb[8] = sizeof(hostrcb->hcam) & 0xff; in ipr_send_hcam()
2378 ipr_log_hex_data(ioa_cfg, error->cdb, sizeof(error->cdb)); in ipr_log_sis64_device_error()
5028 cmd_pkt->cdb[0] = IPR_RESET_DEVICE; in ipr_device_reset()
5171 cmd_pkt->cdb[0] = IPR_RESET_DEVICE; in ipr_abort_timeout()
5172 cmd_pkt->cdb[2] = IPR_RESET_TYPE_SELECT | IPR_BUS_RESET; in ipr_abort_timeout()
5242 cmd_pkt->cdb[0] = IPR_CANCEL_ALL_REQUESTS; in ipr_cancel_op()
[all …]
D3w-sas.c293 unsigned char *cdb, int use_sg, in twl_scsiop_execute_scsi() argument
317 if (!cdb) in twl_scsiop_execute_scsi()
318 memcpy(command_packet->cdb, srb->cmnd, TW_MAX_CDB_LEN); in twl_scsiop_execute_scsi()
320 memcpy(command_packet->cdb, cdb, TW_MAX_CDB_LEN); in twl_scsiop_execute_scsi()
376 unsigned char cdb[TW_MAX_CDB_LEN]; in twl_aen_read_queue() local
385 memset(&cdb, 0, TW_MAX_CDB_LEN); in twl_aen_read_queue()
386 cdb[0] = REQUEST_SENSE; /* opcode */ in twl_aen_read_queue()
387 cdb[4] = TW_ALLOCATION_LENGTH; /* allocation length */ in twl_aen_read_queue()
398 if (twl_scsiop_execute_scsi(tw_dev, request_id, cdb, 1, sglist)) { in twl_aen_read_queue()
558 unsigned char cdb[TW_MAX_CDB_LEN]; in twl_aen_drain_queue() local
[all …]
/linux-6.6.21/drivers/isdn/capi/
Dcapiutil.c385 static _cdebbuf *bufprint(_cdebbuf *cdb, char *fmt, ...) in bufprint() argument
390 if (!cdb) in bufprint()
393 r = cdb->size - cdb->pos; in bufprint()
394 n = vsnprintf(cdb->p, r, fmt, f); in bufprint()
398 size_t ns = 2 * cdb->size; in bufprint()
401 while ((ns - cdb->pos) <= n) in bufprint()
405 cdebbuf_free(cdb); in bufprint()
408 memcpy(nb, cdb->buf, cdb->pos); in bufprint()
409 kfree(cdb->buf); in bufprint()
410 nb[cdb->pos] = 0; in bufprint()
[all …]
Dkcapi.c307 _cdebbuf *cdb; in capi_ctr_handle_message() local
310 cdb = capi_message2str(skb->data); in capi_ctr_handle_message()
311 if (cdb) { in capi_ctr_handle_message()
313 ctr->cnr, cdb->buf); in capi_ctr_handle_message()
314 cdebbuf_free(cdb); in capi_ctr_handle_message()
340 cdb = capi_message2str(skb->data); in capi_ctr_handle_message()
341 if (cdb) { in capi_ctr_handle_message()
343 ctr->cnr, cdb->buf); in capi_ctr_handle_message()
344 cdebbuf_free(cdb); in capi_ctr_handle_message()
358 cdb = capi_message2str(skb->data); in capi_ctr_handle_message()
[all …]
/linux-6.6.21/drivers/target/
Dtarget_core_sbc.c35 unsigned char *cdb = cmd->t_task_cdb; in sbc_emulate_readcapacity() local
53 if (!(cdb[8] & 1) && !!(cdb[2] | cdb[3] | cdb[4] | cdb[5])) in sbc_emulate_readcapacity()
140 unsigned char *cdb = cmd->t_task_cdb; in sbc_emulate_startstop() local
147 if (!(cdb[1] & 1) || cdb[2] || cdb[3]) in sbc_emulate_startstop()
154 if (cdb[4] >> 4 & 0xf) in sbc_emulate_startstop()
162 if (!(cdb[4] & 1) || (cdb[4] & 2) || (cdb[4] & 4)) in sbc_emulate_startstop()
221 static inline u32 transport_get_sectors_6(unsigned char *cdb) in transport_get_sectors_6() argument
231 return cdb[4] ? : 256; in transport_get_sectors_6()
234 static inline u32 transport_get_sectors_10(unsigned char *cdb) in transport_get_sectors_10() argument
236 return get_unaligned_be16(&cdb[7]); in transport_get_sectors_10()
[all …]
Dtarget_core_spc.c737 unsigned char *cdb = cmd->t_task_cdb; in spc_emulate_inquiry() local
751 if (!(cdb[1] & 0x1)) { in spc_emulate_inquiry()
752 if (cdb[2]) { in spc_emulate_inquiry()
754 cdb[2]); in spc_emulate_inquiry()
765 if (cdb[2] == evpd_handlers[p].page) { in spc_emulate_inquiry()
766 buf[1] = cdb[2]; in spc_emulate_inquiry()
773 pr_debug("Unknown VPD Code: 0x%02x\n", cdb[2]); in spc_emulate_inquiry()
1021 char *cdb = cmd->t_task_cdb; in spc_emulate_modesense() local
1025 bool dbd = !!(cdb[1] & 0x08); in spc_emulate_modesense()
1026 bool llba = ten ? !!(cdb[1] & 0x10) : false; in spc_emulate_modesense()
[all …]
Dtarget_core_pscsi.c136 unsigned char cdb[MAX_COMMAND_SIZE], *buf; in pscsi_tape_read_blocksize() local
143 memset(cdb, 0, MAX_COMMAND_SIZE); in pscsi_tape_read_blocksize()
144 cdb[0] = MODE_SENSE; in pscsi_tape_read_blocksize()
145 cdb[4] = 0x0c; /* 12 bytes */ in pscsi_tape_read_blocksize()
147 ret = scsi_execute_cmd(sdev, cdb, REQ_OP_DRV_IN, buf, 12, HZ, 1, NULL); in pscsi_tape_read_blocksize()
184 unsigned char cdb[MAX_COMMAND_SIZE], *buf; in pscsi_get_inquiry_vpd_serial() local
191 memset(cdb, 0, MAX_COMMAND_SIZE); in pscsi_get_inquiry_vpd_serial()
192 cdb[0] = INQUIRY; in pscsi_get_inquiry_vpd_serial()
193 cdb[1] = 0x01; /* Query VPD */ in pscsi_get_inquiry_vpd_serial()
194 cdb[2] = 0x80; /* Unit Serial Number */ in pscsi_get_inquiry_vpd_serial()
[all …]
Dtarget_core_device.c1061 unsigned char *cdb = cmd->t_task_cdb; in passthrough_parse_cdb() local
1069 if (cdb[0] == REPORT_LUNS) { in passthrough_parse_cdb()
1079 ((cdb[0] == PERSISTENT_RESERVE_IN) || in passthrough_parse_cdb()
1080 (cdb[0] == PERSISTENT_RESERVE_OUT) || in passthrough_parse_cdb()
1081 (cdb[0] == RELEASE || cdb[0] == RELEASE_10) || in passthrough_parse_cdb()
1082 (cdb[0] == RESERVE || cdb[0] == RESERVE_10))) { in passthrough_parse_cdb()
1093 if (cdb[0] == PERSISTENT_RESERVE_IN) { in passthrough_parse_cdb()
1095 size = get_unaligned_be16(&cdb[7]); in passthrough_parse_cdb()
1098 if (cdb[0] == PERSISTENT_RESERVE_OUT) { in passthrough_parse_cdb()
1100 size = get_unaligned_be32(&cdb[5]); in passthrough_parse_cdb()
[all …]
Dtarget_core_xcopy.c514 unsigned char *cdb, in target_xcopy_setup_pt_cmd() argument
532 if (target_cmd_init_cdb(cmd, cdb, GFP_KERNEL)) in target_xcopy_setup_pt_cmd()
580 unsigned char cdb[16]; in target_xcopy_read_source() local
586 memset(&cdb[0], 0, 16); in target_xcopy_read_source()
587 cdb[0] = READ_16; in target_xcopy_read_source()
588 put_unaligned_be64(src_lba, &cdb[2]); in target_xcopy_read_source()
589 put_unaligned_be32(transfer_length_block, &cdb[10]); in target_xcopy_read_source()
596 rc = target_xcopy_setup_pt_cmd(&xpt_cmd, xop, src_dev, &cdb[0], in target_xcopy_read_source()
625 unsigned char cdb[16]; in target_xcopy_write_destination() local
631 memset(&cdb[0], 0, 16); in target_xcopy_write_destination()
[all …]
Dtarget_core_alua.c436 unsigned char *cdb, in core_alua_state_nonoptimized() argument
520 unsigned char *cdb) in core_alua_state_standby() argument
526 switch (cdb[0]) { in core_alua_state_standby()
538 switch (cdb[1] & 0x1f) { in core_alua_state_standby()
545 switch (cdb[1] & 0x1f) { in core_alua_state_standby()
552 switch (cdb[1]) { in core_alua_state_standby()
573 unsigned char *cdb) in core_alua_state_unavailable() argument
579 switch (cdb[0]) { in core_alua_state_unavailable()
584 switch (cdb[1] & 0x1f) { in core_alua_state_unavailable()
591 switch (cdb[1]) { in core_alua_state_unavailable()
[all …]
/linux-6.6.21/drivers/ata/
Dlibata-scsi.c1212 const u8 *cdb = scmd->cmnd; in ata_scsi_start_stop_xlat() local
1223 if (cdb[1] & 0x1) { in ata_scsi_start_stop_xlat()
1226 if (cdb[4] & 0x2) { in ata_scsi_start_stop_xlat()
1231 if (((cdb[4] >> 4) & 0xf) != 0) { in ata_scsi_start_stop_xlat()
1237 if (cdb[4] & 0x1) { in ata_scsi_start_stop_xlat()
1330 static void scsi_6_lba_len(const u8 *cdb, u64 *plba, u32 *plen) in scsi_6_lba_len() argument
1335 lba |= ((u64)(cdb[1] & 0x1f)) << 16; in scsi_6_lba_len()
1336 lba |= ((u64)cdb[2]) << 8; in scsi_6_lba_len()
1337 lba |= ((u64)cdb[3]); in scsi_6_lba_len()
1339 len = cdb[4]; in scsi_6_lba_len()
[all …]
Dlibata-zpodd.c38 static const char cdb[ATAPI_CDB_LEN] = { GPCMD_START_STOP_UNIT, in eject_tray() local
49 return ata_exec_internal(dev, &tf, cdb, DMA_NONE, NULL, 0, 0); in eject_tray()
59 static const char cdb[ATAPI_CDB_LEN] = { GPCMD_GET_CONFIGURATION, in zpodd_get_mech_type() local
78 ret = ata_exec_internal(dev, &tf, cdb, DMA_FROM_DEVICE, in zpodd_get_mech_type()
/linux-6.6.21/drivers/dma/
Dfsl_raid.c324 u32 cdb; in fsl_re_prep_dma_genq() local
346 cdb = FSL_RE_XOR_OPCODE << FSL_RE_CDB_OPCODE_SHIFT; in fsl_re_prep_dma_genq()
347 cdb |= (src_cnt - 1) << FSL_RE_CDB_NRCS_SHIFT; in fsl_re_prep_dma_genq()
348 cdb |= FSL_RE_BLOCK_SIZE << FSL_RE_CDB_BLKSIZE_SHIFT; in fsl_re_prep_dma_genq()
349 cdb |= FSL_RE_INTR_ON_ERROR << FSL_RE_CDB_ERROR_SHIFT; in fsl_re_prep_dma_genq()
350 cdb |= FSL_RE_DATA_DEP << FSL_RE_CDB_DEPEND_SHIFT; in fsl_re_prep_dma_genq()
352 xor->cdb32 = cdb; in fsl_re_prep_dma_genq()
411 u32 cdb; in fsl_re_prep_dma_pq() local
465 cdb = FSL_RE_PQ_OPCODE << FSL_RE_CDB_OPCODE_SHIFT; in fsl_re_prep_dma_pq()
466 cdb |= (src_cnt - 1) << FSL_RE_CDB_NRCS_SHIFT; in fsl_re_prep_dma_pq()
[all …]
/linux-6.6.21/drivers/scsi/esas2r/
Desas2r_io.c533 u8 *cdb = (u8 *)&rq->vrq->scsi.cdb[0]; in esas2r_build_sg_list_prd() local
545 switch (rq->vrq->scsi.cdb[0]) { in esas2r_build_sg_list_prd()
550 MAKEDWORD(MAKEWORD(cdb[9], in esas2r_build_sg_list_prd()
551 cdb[8]), in esas2r_build_sg_list_prd()
552 MAKEWORD(cdb[7], in esas2r_build_sg_list_prd()
553 cdb[6])); in esas2r_build_sg_list_prd()
564 MAKEDWORD(MAKEWORD(cdb[5], in esas2r_build_sg_list_prd()
565 cdb[4]), in esas2r_build_sg_list_prd()
566 MAKEWORD(cdb[3], in esas2r_build_sg_list_prd()
567 cdb[2])); in esas2r_build_sg_list_prd()
[all …]
/linux-6.6.21/include/trace/events/
Dtarget.h145 __array( unsigned char, cdb, TCM_MAX_COMMAND_SIZE )
156 memcpy(__entry->cdb, cmd->t_task_cdb, TCM_MAX_COMMAND_SIZE);
163 __entry->data_length, __print_hex(__entry->cdb, 16),
184 __array( unsigned char, cdb, TCM_MAX_COMMAND_SIZE )
199 memcpy(__entry->cdb, cmd->t_task_cdb, TCM_MAX_COMMAND_SIZE);
211 __entry->data_length, __print_hex(__entry->cdb, 16),
/linux-6.6.21/drivers/scsi/megaraid/
Dmegaraid_sas_fusion.c2392 u8 *cdb = io_request->CDB.CDB32; in megasas_set_pd_lba() local
2400 memset(cdb, 0, sizeof(io_request->CDB.CDB32)); in megasas_set_pd_lba()
2401 cdb[0] = MEGASAS_SCSI_VARIABLE_LENGTH_CMD; in megasas_set_pd_lba()
2402 cdb[7] = MEGASAS_SCSI_ADDL_CDB_LEN; in megasas_set_pd_lba()
2405 cdb[9] = MEGASAS_SCSI_SERVICE_ACTION_READ32; in megasas_set_pd_lba()
2407 cdb[9] = MEGASAS_SCSI_SERVICE_ACTION_WRITE32; in megasas_set_pd_lba()
2408 cdb[10] = MEGASAS_RD_WR_PROTECT_CHECK_ALL; in megasas_set_pd_lba()
2411 cdb[12] = (u8)((start_blk >> 56) & 0xff); in megasas_set_pd_lba()
2412 cdb[13] = (u8)((start_blk >> 48) & 0xff); in megasas_set_pd_lba()
2413 cdb[14] = (u8)((start_blk >> 40) & 0xff); in megasas_set_pd_lba()
[all …]
/linux-6.6.21/drivers/scsi/device_handler/
Dscsi_dh_emc.c239 unsigned char cdb[MAX_COMMAND_SIZE]; in send_trespass_cmd() local
254 cdb[0] = MODE_SELECT; in send_trespass_cmd()
255 cdb[1] = 0x10; in send_trespass_cmd()
256 cdb[4] = len; in send_trespass_cmd()
263 cdb[0] = MODE_SELECT_10; in send_trespass_cmd()
264 cdb[8] = len; in send_trespass_cmd()
269 err = scsi_execute_cmd(sdev, cdb, opf, csdev->buffer, len, in send_trespass_cmd()
Dscsi_dh_rdac.c266 unsigned char *cdb) in rdac_failover_get() argument
306 cdb[0] = MODE_SELECT_10; in rdac_failover_get()
307 cdb[7] = data_size >> 8; in rdac_failover_get()
308 cdb[8] = data_size & 0xff; in rdac_failover_get()
310 cdb[0] = MODE_SELECT; in rdac_failover_get()
311 cdb[4] = data_size; in rdac_failover_get()
536 unsigned char cdb[MAX_COMMAND_SIZE]; in send_mode_select() local
552 memset(cdb, 0, sizeof(cdb)); in send_mode_select()
554 data_size = rdac_failover_get(ctlr, &list, cdb); in send_mode_select()
561 if (scsi_execute_cmd(sdev, cdb, opf, &h->ctlr->mode_select, data_size, in send_mode_select()
Dscsi_dh_alua.c129 u8 cdb[MAX_COMMAND_SIZE]; in submit_rtpg() local
137 memset(cdb, 0x0, MAX_COMMAND_SIZE); in submit_rtpg()
138 cdb[0] = MAINTENANCE_IN; in submit_rtpg()
140 cdb[1] = MI_REPORT_TARGET_PGS | MI_EXT_HDR_PARAM_FMT; in submit_rtpg()
142 cdb[1] = MI_REPORT_TARGET_PGS; in submit_rtpg()
143 put_unaligned_be32(bufflen, &cdb[6]); in submit_rtpg()
145 return scsi_execute_cmd(sdev, cdb, opf, buff, bufflen, in submit_rtpg()
160 u8 cdb[MAX_COMMAND_SIZE]; in submit_stpg() local
175 memset(cdb, 0x0, MAX_COMMAND_SIZE); in submit_stpg()
176 cdb[0] = MAINTENANCE_OUT; in submit_stpg()
[all …]
/linux-6.6.21/drivers/scsi/ibmvscsi_tgt/
Dibmvscsi_tgt.h337 #define READ_CMD(cdb) (((cdb)[0] & 0x1F) == 8) argument
338 #define WRITE_CMD(cdb) (((cdb)[0] & 0x1F) == 0xA) argument
/linux-6.6.21/drivers/usb/storage/
Dene_ub6250.c674 unsigned char *cdb = srb->cmnd; in sd_scsi_read() local
678 u32 bn = ((cdb[2] << 24) & 0xff000000) | ((cdb[3] << 16) & 0x00ff0000) | in sd_scsi_read()
679 ((cdb[4] << 8) & 0x0000ff00) | ((cdb[5] << 0) & 0x000000ff); in sd_scsi_read()
680 u16 blen = ((cdb[7] << 8) & 0xff00) | ((cdb[8] << 0) & 0x00ff); in sd_scsi_read()
714 unsigned char *cdb = srb->cmnd; in sd_scsi_write() local
718 u32 bn = ((cdb[2] << 24) & 0xff000000) | ((cdb[3] << 16) & 0x00ff0000) | in sd_scsi_write()
719 ((cdb[4] << 8) & 0x0000ff00) | ((cdb[5] << 0) & 0x000000ff); in sd_scsi_write()
720 u16 blen = ((cdb[7] << 8) & 0xff00) | ((cdb[8] << 0) & 0x00ff); in sd_scsi_write()
1638 unsigned char *cdb = srb->cmnd; in ms_scsi_read() local
1642 u32 bn = ((cdb[2] << 24) & 0xff000000) | ((cdb[3] << 16) & 0x00ff0000) | in ms_scsi_read()
[all …]
/linux-6.6.21/include/uapi/linux/
Dvirtio_scsi.h50 __u8 cdb[VIRTIO_SCSI_CDB_SIZE]; member
62 __u8 cdb[VIRTIO_SCSI_CDB_SIZE]; member
/linux-6.6.21/drivers/scsi/mpi3mr/mpi/
Dmpi30_init.h8 u8 cdb[20]; member
34 union mpi3_scsi_io_cdb_union cdb; member

1234567