/openbmc/linux/drivers/scsi/ |
H A D | scsi_error.c | 814 if (scmd->sense_buffer && SCSI_SENSE_VALID(scmd)) in scsi_eh_completed_normally() 1062 memset(scmd->cmnd, 0, sizeof(scmd->cmnd)); in scsi_eh_prep_cmnd() 1063 memset(&scmd->sdb, 0, sizeof(scmd->sdb)); in scsi_eh_prep_cmnd() 1076 scmd->cmnd[4] = scmd->sdb.length; in scsi_eh_prep_cmnd() 1077 scmd->cmd_len = COMMAND_SIZE(scmd->cmnd[0]); in scsi_eh_prep_cmnd() 1083 scmd->cmd_len = COMMAND_SIZE(scmd->cmnd[0]); in scsi_eh_prep_cmnd() 1090 scmd->cmnd[1] = (scmd->cmnd[1] & 0x1f) | in scsi_eh_prep_cmnd() 1363 scmd->retries = scmd->allowed = 1; in scsi_eh_get_sense() 1365 scmd->retries = scmd->allowed; in scsi_eh_get_sense() 2097 scmd->cmd_len = COMMAND_SIZE(scmd->cmnd[0]); in scsi_eh_lock_door() [all …]
|
H A D | scsi_bsg.c | 15 struct scsi_cmnd *scmd; in scsi_bsg_sg_io_fn() local 34 scmd = blk_mq_rq_to_pdu(rq); in scsi_bsg_sg_io_fn() 35 scmd->cmd_len = hdr->request_len; in scsi_bsg_sg_io_fn() 36 if (scmd->cmd_len > sizeof(scmd->cmnd)) { in scsi_bsg_sg_io_fn() 42 if (copy_from_user(scmd->cmnd, uptr64(hdr->request), scmd->cmd_len)) in scsi_bsg_sg_io_fn() 66 hdr->device_status = scmd->result & 0xff; in scsi_bsg_sg_io_fn() 67 hdr->transport_status = host_byte(scmd->result); in scsi_bsg_sg_io_fn() 76 if (scmd->sense_len && hdr->response) { in scsi_bsg_sg_io_fn() 78 scmd->sense_len); in scsi_bsg_sg_io_fn() 88 hdr->din_resid = scmd->resid_len; in scsi_bsg_sg_io_fn() [all …]
|
H A D | myrb.c | 1286 scsi_done(scmd); in myrb_pthru_queuecommand() 1331 memcpy(&dcdb->cdb, scmd->cmnd, scmd->cmd_len); in myrb_pthru_queuecommand() 1403 scsi_sg_copy_from_buffer(scmd, scmd->sense_buffer, in myrb_request_sense() 1440 scsi_done(scmd); in myrb_ldev_queuecommand() 1446 scsi_done(scmd); in myrb_ldev_queuecommand() 1456 scsi_done(scmd); in myrb_ldev_queuecommand() 2369 scsi_done(scmd); in myrb_handle_scsi() 2730 if (scmd) in DAC960_LA_intr_handler() 2978 if (scmd) in DAC960_PG_intr_handler() 3171 if (scmd) in DAC960_PD_intr_handler() [all …]
|
H A D | scsi_ioctl.c | 359 scmd->cmd_len = hdr->cmd_len; in scsi_fill_sghdr_rq() 418 struct scsi_cmnd *scmd; in sg_io() local 445 scmd = blk_mq_rq_to_pdu(rq); in sg_io() 463 scmd->allowed = 0; in sg_io() 510 struct scsi_cmnd *scmd; in sg_scsi_ioctl() local 541 scmd = blk_mq_rq_to_pdu(rq); in sg_scsi_ioctl() 549 scmd->cmd_len = cmdlen; in sg_scsi_ioctl() 561 scmd->allowed = 5; in sg_scsi_ioctl() 567 scmd->allowed = 1; in sg_scsi_ioctl() 580 scmd->allowed = 1; in sg_scsi_ioctl() [all …]
|
H A D | mvumi.c | 338 cmd->scmd = NULL; in mvumi_return_cmd() 705 scsi_cmd_to_rq(scmd)->tag, scmd->cmnd[0], scmd->retries); in mvumi_host_reset() 1303 struct scsi_cmnd *scmd = cmd->scmd; in mvumi_complete_cmd() local 1331 scsi_done(scmd); in mvumi_complete_cmd() 1428 cmd->scmd = NULL; in mvumi_inquiry() 1707 cmd->scmd = NULL; in mvumi_get_event() 1782 if (cmd->scmd) in mvumi_handle_clob() 2030 cmd->scmd = scmd; in mvumi_build_frame() 2050 "cmd[0x%x]\n", scmd->sc_data_direction, scmd->cmnd[0]); in mvumi_build_frame() 2099 cmd->scmd = scmd; in mvumi_queue_command() [all …]
|
H A D | myrs.c | 1600 scsi_done(scmd); in myrs_queuecommand() 1607 scsi_done(scmd); in myrs_queuecommand() 1621 scsi_done(scmd); in myrs_queuecommand() 1666 memcpy(&mbox->SCSI_10.cdb, scmd->cmnd, scmd->cmd_len); in myrs_queuecommand() 1713 memcpy(cmd_blk->dcdb, scmd->cmnd, scmd->cmd_len); in myrs_queuecommand() 1761 scsi_done(scmd); in myrs_queuecommand() 2054 scsi_dma_unmap(scmd); in myrs_handle_scsi() 2088 scsi_done(scmd); in myrs_handle_scsi() 2594 if (scmd) in DAC960_GEM_intr_handler() 2813 if (scmd) in DAC960_BA_intr_handler() [all …]
|
H A D | sr.c | 929 struct scsi_cmnd *scmd; in sr_read_cdda_bpc() local 937 scmd = blk_mq_rq_to_pdu(rq); in sr_read_cdda_bpc() 943 scmd->cmnd[0] = GPCMD_READ_CD; in sr_read_cdda_bpc() 944 scmd->cmnd[1] = 1 << 2; in sr_read_cdda_bpc() 948 scmd->cmnd[5] = lba & 0xff; in sr_read_cdda_bpc() 949 scmd->cmnd[6] = (nr >> 16) & 0xff; in sr_read_cdda_bpc() 951 scmd->cmnd[8] = nr & 0xff; in sr_read_cdda_bpc() 952 scmd->cmnd[9] = 0xf8; in sr_read_cdda_bpc() 953 scmd->cmd_len = 12; in sr_read_cdda_bpc() 958 if (scmd->result) { in sr_read_cdda_bpc() [all …]
|
H A D | scsi_priv.h | 43 #define SCSI_SENSE_VALID(scmd) \ argument 44 (((scmd)->sense_buffer[0] & 0x70) == 0x70) 102 bool scsi_noretry_cmd(struct scsi_cmnd *scmd); 103 void scsi_eh_done(struct scsi_cmnd *scmd);
|
H A D | scsi_logging.c | 29 static inline const char *scmd_name(const struct scsi_cmnd *scmd) in scmd_name() argument 31 struct request *rq = scsi_cmd_to_rq((struct scsi_cmnd *)scmd); in scmd_name() 83 void scmd_printk(const char *level, const struct scsi_cmnd *scmd, in scmd_printk() argument 90 if (!scmd) in scmd_printk() 96 off = sdev_format_header(logbuf, logbuf_len, scmd_name(scmd), in scmd_printk() 97 scsi_cmd_to_rq((struct scsi_cmnd *)scmd)->tag); in scmd_printk() 103 dev_printk(level, &scmd->device->sdev_gendev, "%s", logbuf); in scmd_printk()
|
/openbmc/linux/include/scsi/ |
H A D | scsi_cmnd.h | 149 return blk_mq_rq_from_pdu(scmd); in scsi_cmd_to_rq() 225 return blk_rq_pos(scsi_cmd_to_rq(scmd)); in scsi_get_sector() 232 return blk_rq_pos(scsi_cmd_to_rq(scmd)) >> shift; in scsi_get_lba() 265 scmd->prot_op = op; in scsi_set_prot_op() 270 return scmd->prot_op; in scsi_get_prot_op() 296 scmd->prot_type = type; in scsi_set_prot_type() 301 return scmd->prot_type; in scsi_get_prot_type() 306 struct request *rq = blk_mq_rq_from_pdu(scmd); in scsi_prot_ref_tag() 313 return scmd->device->sector_size; in scsi_prot_interval() 383 unsigned int xfer_len = scmd->sdb.length; in scsi_transfer_length() [all …]
|
H A D | scsi_eh.h | 12 extern void scsi_eh_finish_cmd(struct scsi_cmnd *scmd, 46 extern void scsi_eh_prep_cmnd(struct scsi_cmnd *scmd, 50 extern void scsi_eh_restore_cmnd(struct scsi_cmnd* scmd,
|
H A D | scsi_device.h | 311 #define scmd_dbg(scmd, fmt, a...) \ argument 313 struct request *__rq = scsi_cmd_to_rq((scmd)); \ 316 sdev_dbg((scmd)->device, "[%s] " fmt, \ 319 sdev_dbg((scmd)->device, fmt, ##a); \ 533 #define scmd_id(scmd) sdev_id((scmd)->device) argument 534 #define scmd_channel(scmd) sdev_channel((scmd)->device) argument
|
/openbmc/linux/drivers/scsi/mpi3mr/ |
H A D | mpi3mr_os.c | 80 priv->scmd = scmd; in mpi3mr_host_tag_for_scmd() 113 if (scmd) { in mpi3mr_scmd_from_host_tag() 116 scmd = NULL; in mpi3mr_scmd_from_host_tag() 119 return scmd; in mpi3mr_scmd_from_host_tag() 455 if (scmd) { in mpi3mr_print_scmd() 486 if (scmd) { in mpi3mr_flush_scmd() 493 scsi_prot_sg_count(scmd), scmd->sc_data_direction); in mpi3mr_flush_scmd() 526 if (scmd) { in mpi3mr_count_dev_pending() 558 if (scmd) { in mpi3mr_count_tgt_pending() 3695 if (scmd) { in mpi3mr_issue_tm() [all …]
|
/openbmc/linux/Documentation/scsi/ |
H A D | scsi_eh.rst | 38 scmd->list and scmd->eh_entry. The former is used for free list or 154 assumed to forget about the scmd at that point. However, if a scmd 205 commands. A scmd is said to be recovered if the scmd is forgotten by 244 When a scmd is recovered, the scmd is moved from eh_work_q to EH 252 scmd->allowed. 276 3. scmd recovered 295 - scmd is removed from eh_done_q and scmd->eh_entry is cleared 340 scmd->retries is set to scmd->allowed preventing 362 the scmd. Otherwise, the scmd is left in eh_work_q for 467 - Each failed scmd is linked on scmd->eh_cmd_q by scmd->eh_entry. [all …]
|
/openbmc/linux/drivers/s390/scsi/ |
H A D | zfcp_dbf.h | 391 scmd->device->host->hostdata[0]; in _zfcp_dbf_scsi() 394 zfcp_dbf_scsi_common(tag, level, scmd->device, scmd, req); in _zfcp_dbf_scsi() 405 if (scmd->result != 0) in zfcp_dbf_scsi_result() 406 _zfcp_dbf_scsi("rsl_err", 3, scmd, req); in zfcp_dbf_scsi_result() 407 else if (scmd->retries > 0) in zfcp_dbf_scsi_result() 408 _zfcp_dbf_scsi("rsl_ret", 4, scmd, req); in zfcp_dbf_scsi_result() 410 _zfcp_dbf_scsi("rsl_nor", 6, scmd, req); in zfcp_dbf_scsi_result() 418 void zfcp_dbf_scsi_fail_send(struct scsi_cmnd *scmd) in zfcp_dbf_scsi_fail_send() argument 420 _zfcp_dbf_scsi("rsl_fai", 4, scmd, NULL); in zfcp_dbf_scsi_fail_send() 430 void zfcp_dbf_scsi_abort(char *tag, struct scsi_cmnd *scmd, in zfcp_dbf_scsi_abort() argument [all …]
|
/openbmc/linux/drivers/ata/ |
H A D | libata-scsi.c | 1216 if (scmd->cmd_len < 5) { in ata_scsi_start_stop_xlat() 1417 if (scmd->cmd_len < 10) { in ata_scsi_verify_xlat() 1424 if (scmd->cmd_len < 16) { in ata_scsi_verify_xlat() 2681 memcpy(qc->cdb, scmd->cmnd, scmd->cmd_len); in atapi_xlat() 3255 if (!scsi_sg_count(scmd)) in ata_scsi_write_same_xlat() 3417 sg_miter_start(&miter, scsi_sglist(scmd), scsi_sg_count(scmd), in ata_scsi_report_zones_complete() 3485 scmd->cmd_len); in ata_scsi_zbc_in_xlat() 3833 if (scmd->cmd_len < 5) { in ata_scsi_mode_select_xlat() 3858 if (!scsi_sg_count(scmd) || scsi_sglist(scmd)->length < len) in ata_scsi_mode_select_xlat() 3865 if (!sg_copy_to_buffer(scsi_sglist(scmd), scsi_sg_count(scmd), in ata_scsi_mode_select_xlat() [all …]
|
/openbmc/linux/drivers/macintosh/ |
H A D | smu.c | 302 memset(scmd, 0, sizeof(*scmd)); in smu_queue_simple() 305 cmd->data_buf = scmd->buffer; in smu_queue_simple() 765 smu_queue_cmd(&cmd->scmd); in smu_i2c_retry() 775 cmd->stage, scmd->status, cmd->pdata[0], scmd->reply_len); in smu_i2c_low_completion() 778 if (scmd->status < 0) in smu_i2c_low_completion() 814 scmd->data_buf = cmd->pdata; in smu_i2c_low_completion() 815 scmd->data_len = 1; in smu_i2c_low_completion() 819 smu_queue_cmd(scmd); in smu_i2c_low_completion() 833 cmd->scmd.misc = cmd; in smu_queue_i2c() 837 cmd->scmd.status = 1; in smu_queue_i2c() [all …]
|
/openbmc/linux/drivers/scsi/mpt3sas/ |
H A D | mpt3sas_scsih.c | 1699 if (!scmd) in _scsih_scsi_lookup_find_by_target() 1729 if (!scmd) in _scsih_scsi_lookup_find_by_lun() 1772 if (scmd) { in mpt3sas_scsih_scsi_lookup_get() 1778 return scmd; in mpt3sas_scsih_scsi_lookup_get() 3347 scmd->device->id, scmd->device->lun, in scsih_abort() 3424 scmd->device->id, scmd->device->lun, in scsih_dev_reset() 5021 if (!scmd) in _scsih_flush_running_cmds() 5499 scsi_bufflen(scmd), scmd->underflow, scsi_get_resid(scmd)); in _scsih_scsi_ioc_info() 5751 st->scmd = scmd; in _scsih_io_done() 5777 scsi_set_resid(scmd, scsi_bufflen(scmd) - xfer_cnt); in _scsih_io_done() [all …]
|
H A D | mpt3sas_warpdrive.c | 256 mpt3sas_setup_direct_io(struct MPT3SAS_ADAPTER *ioc, struct scsi_cmnd *scmd, in mpt3sas_setup_direct_io() argument 261 u8 num_pds, cmd = scmd->cmnd[0]; in mpt3sas_setup_direct_io() 262 struct scsiio_tracker *st = scsi_cmd_priv(scmd); in mpt3sas_setup_direct_io() 273 io_size = scsi_bufflen(scmd) >> raid_device->block_exponent; in mpt3sas_setup_direct_io()
|
/openbmc/linux/drivers/scsi/smartpqi/ |
H A D | smartpqi_init.c | 3162 scmd = io_request->scmd; in pqi_process_raid_io_error() 3264 scmd = io_request->scmd; in pqi_process_aio_io_error() 5523 scmd = io_request->scmd; in pqi_raid_io_complete() 5543 io_request->scmd = scmd; in pqi_raid_submit_io() 5633 scmd = io_request->scmd; in pqi_raid_bypass_retry_needed() 5655 scmd = io_request->scmd; in pqi_aio_io_complete() 5694 io_request->scmd = scmd; in pqi_aio_submit_io() 5769 io_request->scmd = scmd; in pqi_aio_submit_r1_write_io() 5829 io_request->scmd = scmd; in pqi_aio_submit_r56_write_io() 8999 scmd = io_request->scmd; in pqi_fail_all_outstanding_requests() [all …]
|
/openbmc/linux/drivers/scsi/megaraid/ |
H A D | megaraid_sas_fusion.c | 229 scmd->device->hostdata; in megasas_sdev_busy_inc() 240 scmd->device->hostdata; in megasas_sdev_busy_dec() 281 cmd->scmd = NULL; in megasas_return_cmd_fusion() 1009 cmd->scmd = NULL; in megasas_alloc_cmds_fusion() 3295 cmd->scmd = scp; in megasas_build_io_fusion() 3334 r1_cmd->scmd = cmd->scmd; in megasas_prepare_secondRaid1_IO() 4674 if (cmd_fusion->scmd && (cmd_fusion->scmd == scmd)) { in megasas_fusion_smid_lookup() 4782 scmd, devhandle); in megasas_task_abort_fusion() 4786 scmd->device->channel, scmd->device->id, smid, in megasas_task_abort_fusion() 4853 scmd, devhandle); in megasas_reset_target_fusion() [all …]
|
H A D | megaraid_sas_base.c | 364 cmd->scmd = NULL; in megasas_return_cmd() 1694 if (!cmd->scmd) in megasas_dump_pending_frames() 1762 cmd->scmd = scmd; in megasas_build_and_issue_cmd() 1797 scsi_done(scmd); in megasas_queue_command() 1812 scsi_done(scmd); in megasas_queue_command() 1821 scsi_done(scmd); in megasas_queue_command() 1841 scmd->result = 0; in megasas_queue_command() 1860 scsi_done(scmd); in megasas_queue_command() 2907 scmd->cmnd[0], scmd->retries); in megasas_generic_reset() 3009 scmd, scmd->retries, scmd->allowed); in megasas_dump_fusion_io() [all …]
|
/openbmc/qemu/hw/scsi/ |
H A D | trace-events | 48 megasas_initq_map_failed(int frame) "scmd %d: failed to map queue" 56 megasas_qf_map_failed(int cmd, unsigned long frame) "scmd %d: frame %lu" 71 megasas_scsi_nodata(int cmd) "scmd %d: no data to be transferred" 78 megasas_io_complete(int cmd, uint32_t len) "scmd %d: %d bytes" 86 megasas_dcmd_req_alloc_failed(int cmd, const char *desc) "scmd %d: %s" 89 megasas_dcmd_internal_invalid(int cmd, int opcode) "scmd %d: DCMD 0x%x" 91 megasas_dcmd_zero_sge(int cmd) "scmd %d: zero DCMD sge count" 99 megasas_dcmd_ld_get_info(int cmd, int ld_id) "scmd %d: dev %d" 101 megasas_dcmd_pd_get_info(int cmd, int pd_id) "scmd %d: dev %d" 103 megasas_dcmd_reset_ld(int cmd, int target_id) "scmd %d: dev %d" [all …]
|
/openbmc/linux/drivers/target/ |
H A D | target_core_pscsi.c | 939 struct scsi_cmnd *scmd; in pscsi_execute_cmd() local 958 scmd = blk_mq_rq_to_pdu(req); in pscsi_execute_cmd() 959 scmd->cmd_len = scsi_command_size(cmd->t_task_cdb); in pscsi_execute_cmd() 960 if (scmd->cmd_len > sizeof(scmd->cmnd)) { in pscsi_execute_cmd() 964 memcpy(scmd->cmnd, cmd->t_task_cdb, scmd->cmd_len); in pscsi_execute_cmd() 971 scmd->allowed = PS_RETRY; in pscsi_execute_cmd() 973 cmd->priv = scmd->cmnd; in pscsi_execute_cmd() 1009 struct scsi_cmnd *scmd = blk_mq_rq_to_pdu(req); in pscsi_req_done() local 1010 enum sam_status scsi_status = scmd->result & 0xff; in pscsi_req_done() 1011 int valid_data = cmd->data_length - scmd->resid_len; in pscsi_req_done() [all …]
|
/openbmc/linux/arch/powerpc/include/asm/ |
H A D | smu.h | 427 extern int smu_queue_simple(struct smu_simple_cmd *scmd, u8 command, 445 static inline void smu_spinwait_simple(struct smu_simple_cmd *scmd) in smu_spinwait_simple() argument 447 smu_spinwait_cmd(&scmd->cmd); in smu_spinwait_simple() 503 struct smu_cmd scmd; member
|