/drivers/scsi/ |
D | scsi_common.c | 137 bool scsi_normalize_sense(const u8 *sense_buffer, int sb_len, in scsi_normalize_sense() argument 140 if (!sense_buffer || !sb_len) in scsi_normalize_sense() 145 sshdr->response_code = (sense_buffer[0] & 0x7f); in scsi_normalize_sense() 155 sshdr->sense_key = (sense_buffer[1] & 0xf); in scsi_normalize_sense() 157 sshdr->asc = sense_buffer[2]; in scsi_normalize_sense() 159 sshdr->ascq = sense_buffer[3]; in scsi_normalize_sense() 161 sshdr->additional_length = sense_buffer[7]; in scsi_normalize_sense() 167 sshdr->sense_key = (sense_buffer[2] & 0xf); in scsi_normalize_sense() 169 sb_len = (sb_len < (sense_buffer[7] + 8)) ? in scsi_normalize_sense() 170 sb_len : (sense_buffer[7] + 8); in scsi_normalize_sense() [all …]
|
D | scsi_logging.c | 340 const unsigned char *sense_buffer, int sense_len) in scsi_log_dump_sense() argument 356 hex_dump_to_buffer(&sense_buffer[i], len, 16, 1, in scsi_log_dump_sense() 391 const unsigned char *sense_buffer, int sense_len) in scsi_log_print_sense() argument 395 if (scsi_normalize_sense(sense_buffer, sense_len, &sshdr)) in scsi_log_print_sense() 398 scsi_log_dump_sense(sdev, name, tag, sense_buffer, sense_len); in scsi_log_print_sense() 414 const unsigned char *sense_buffer, int sense_len) in __scsi_print_sense() argument 416 scsi_log_print_sense(sdev, name, -1, sense_buffer, sense_len); in __scsi_print_sense() 424 cmd->sense_buffer, SCSI_SENSE_BUFFERSIZE); in scsi_print_sense()
|
D | scsi_error.c | 491 if (scmd->sense_buffer[2] & 0xe0) in scsi_check_sense() 500 (scmd->sense_buffer[8] == 0x4) && in scsi_check_sense() 501 (scmd->sense_buffer[11] & 0xe0)) in scsi_check_sense() 948 sg_init_one(&ses->sense_sgl, scmd->sense_buffer, in scsi_eh_prep_cmnd() 975 memset(scmd->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); in scsi_eh_prep_cmnd() 2426 return scsi_normalize_sense(cmd->sense_buffer, in scsi_command_normalize_sense() 2441 int scsi_get_sense_info_fld(const u8 * sense_buffer, int sb_len, in scsi_get_sense_info_fld() argument 2450 switch (sense_buffer[0] & 0x7f) { in scsi_get_sense_info_fld() 2453 if (sense_buffer[0] & 0x80) { in scsi_get_sense_info_fld() 2454 *info_out = (sense_buffer[3] << 24) + in scsi_get_sense_info_fld() [all …]
|
D | sr.c | 338 (SCpnt->sense_buffer[0] & 0x7f) == 0x70) { /* Sense current */ in sr_done() 339 switch (SCpnt->sense_buffer[2]) { in sr_done() 343 if (!(SCpnt->sense_buffer[0] & 0x90)) in sr_done() 345 error_sector = (SCpnt->sense_buffer[3] << 24) | in sr_done() 346 (SCpnt->sense_buffer[4] << 16) | in sr_done() 347 (SCpnt->sense_buffer[5] << 8) | in sr_done() 348 SCpnt->sense_buffer[6]; in sr_done()
|
D | ps3rom.c | 249 memset(cmd->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); in ps3rom_queuecommand_lck() 251 cmd->sense_buffer[0] = 0x70; in ps3rom_queuecommand_lck() 252 cmd->sense_buffer[2] = ILLEGAL_REQUEST; in ps3rom_queuecommand_lck() 334 scsi_build_sense_buffer(0, cmd->sense_buffer, sense_key, asc, ascq); in ps3rom_interrupt()
|
D | scsi.c | 141 kmem_cache_free(pool->sense_slab, cmd->sense_buffer); in scsi_host_free_command() 163 cmd->sense_buffer = kmem_cache_alloc(pool->sense_slab, in scsi_host_alloc_command() 165 if (!cmd->sense_buffer) in scsi_host_alloc_command() 177 kmem_cache_free(pool->sense_slab, cmd->sense_buffer); in scsi_host_alloc_command() 211 buf = cmd->sense_buffer; in __scsi_get_command() 216 cmd->sense_buffer = buf; in __scsi_get_command()
|
D | gdth.c | 458 scp->sense_buffer = kzalloc(SCSI_SENSE_BUFFERSIZE, GFP_KERNEL); in __gdth_execute() 459 if (!scp->sense_buffer) { in __gdth_execute() 483 kfree(scp->sense_buffer); in __gdth_execute() 2126 memset((char*)nscp->sense_buffer,0,16); in gdth_next() 2127 nscp->sense_buffer[0] = 0x70; in gdth_next() 2128 nscp->sense_buffer[2] = NOT_READY; in gdth_next() 2171 memset((char*)nscp->sense_buffer,0,16); in gdth_next() 2172 nscp->sense_buffer[0] = 0x70; in gdth_next() 2173 nscp->sense_buffer[2] = UNIT_ATTENTION; in gdth_next() 2190 nscp->sense_buffer[0] = 0; in gdth_next() [all …]
|
D | stex.c | 295 void *sense_buffer; member 393 scsi_build_sense_buffer(0, cmd->sense_buffer, ILLEGAL_REQUEST, 0x24, in stex_invalid_field() 701 hba->ccb[tag].sense_buffer = cmd->sense_buffer; in stex_queuecommand_lck() 760 if (ccb->sense_buffer != NULL) in stex_copy_data() 761 memcpy(ccb->sense_buffer, resp->variable, in stex_copy_data() 1775 hba->ccb[tag].sense_buffer = NULL; in stex_hba_stop()
|
D | scsi_lib.c | 270 memset(cmd->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); in scsi_init_cmd_errh() 754 int len = 8 + cmd->sense_buffer[7]; in scsi_io_completion() 758 memcpy(req->sense, cmd->sense_buffer, len); in scsi_io_completion() 1818 unsigned char *sense_buf = cmd->sense_buffer; in scsi_mq_prep_fn() 1827 cmd->sense_buffer = sense_buf; in scsi_mq_prep_fn() 1979 cmd->sense_buffer = kzalloc_node(SCSI_SENSE_BUFFERSIZE, GFP_KERNEL, in scsi_init_request() 1981 if (!cmd->sense_buffer) in scsi_init_request() 1991 kfree(cmd->sense_buffer); in scsi_exit_request()
|
D | vmw_pvscsi.c | 431 if (cmd->sense_buffer) in pvscsi_unmap_buffers() 568 if (sdstat == SAM_STAT_CHECK_CONDITION && cmd->sense_buffer) in pvscsi_complete_request() 708 if (cmd->sense_buffer) { in pvscsi_queue_ring() 709 ctx->sensePA = pci_map_single(adapter->dev, cmd->sense_buffer, in pvscsi_queue_ring() 740 if (cmd->sense_buffer) { in pvscsi_queue_ring()
|
D | scsi_priv.h | 25 (((scmd)->sense_buffer[0] & 0x70) == 0x70)
|
D | 3w-xxxx.c | 419 tw_dev->srb[request_id]->sense_buffer[0] = (0x1 << 7 | 0x70); in tw_decode_sense() 422 tw_dev->srb[request_id]->sense_buffer[2] = tw_sense_table[i][1]; in tw_decode_sense() 425 tw_dev->srb[request_id]->sense_buffer[7] = 0xa; /* 10 bytes */ in tw_decode_sense() 428 tw_dev->srb[request_id]->sense_buffer[12] = tw_sense_table[i][2]; in tw_decode_sense() 431 tw_dev->srb[request_id]->sense_buffer[13] = tw_sense_table[i][3]; in tw_decode_sense() 1975 scsi_build_sense_buffer(1, SCpnt->sense_buffer, ILLEGAL_REQUEST, 0x20, 0); in tw_scsi_queue_lck()
|
/drivers/usb/storage/ |
D | transport.c | 595 memcpy(srb->sense_buffer, record_not_found, in last_sector_hacks() 786 if (srb->sense_buffer[7] > (US_SENSE_SIZE - 8) && in usb_stor_invoke_transport() 789 (srb->sense_buffer[0] & 0x7C) == 0x70) { in usb_stor_invoke_transport() 799 srb->sense_buffer[7] + 8); in usb_stor_invoke_transport() 800 srb->sense_buffer[7] = (US_SENSE_SIZE - 8); in usb_stor_invoke_transport() 803 scsi_normalize_sense(srb->sense_buffer, SCSI_SENSE_BUFFERSIZE, in usb_stor_invoke_transport() 818 scdd = scsi_sense_desc_find(srb->sense_buffer, in usb_stor_invoke_transport() 820 fm_ili = (scdd ? scdd[3] : srb->sense_buffer[2]) & 0xA0; in usb_stor_invoke_transport() 836 srb->sense_buffer[0] = 0x0; in usb_stor_invoke_transport() 858 srb->sense_buffer[1] = HARDWARE_ERROR; in usb_stor_invoke_transport() [all …]
|
D | cypress_atacb.c | 164 memcmp(srb->sense_buffer, usb_stor_sense_invalidCDB, in cypress_atacb_passthrough() 179 unsigned char *sb = srb->sense_buffer; in cypress_atacb_passthrough() 196 memcpy(regs, srb->sense_buffer, sizeof(regs)); in cypress_atacb_passthrough() 242 memcpy(srb->sense_buffer, in cypress_atacb_passthrough()
|
D | isd200.c | 414 struct sense_data *buf = (struct sense_data *) &srb->sense_buffer[0]; in isd200_build_sense() 692 if ((srb->sense_buffer[2] & 0xf) == 0x0) in isd200_invoke_transport() 1454 kfree(info->srb.sense_buffer); in isd200_free_info_ptrs() 1476 info->srb.sense_buffer = kmalloc(SCSI_SENSE_BUFFERSIZE, GFP_KERNEL); in isd200_init_info() 1478 if (!info->id || !info->RegsBuf || !info->srb.sense_buffer) { in isd200_init_info()
|
/drivers/xen/ |
D | xen-scsiback.c | 131 uint8_t sense_buffer[VSCSIIF_SENSE_BUFFERSIZE]; member 259 static void scsiback_print_status(char *sense_buffer, int errors, in scsiback_print_status() argument 324 char *sense_buffer, int32_t result, uint32_t resid, in scsiback_send_response() argument 341 if (sense_buffer != NULL && in scsiback_send_response() 342 scsi_normalize_sense(sense_buffer, VSCSIIF_SENSE_BUFFERSIZE, in scsiback_send_response() 344 len = min_t(unsigned, 8 + sense_buffer[7], in scsiback_send_response() 346 memcpy(ring_res->sense_buffer, sense_buffer, len); in scsiback_send_response() 361 static void scsiback_do_resp_with_sense(char *sense_buffer, int32_t result, in scsiback_do_resp_with_sense() argument 364 scsiback_send_response(pending_req->info, sense_buffer, result, in scsiback_do_resp_with_sense() 375 unsigned char *sense_buffer; in scsiback_cmd_done() local [all …]
|
/drivers/message/fusion/ |
D | mptscsih.c | 554 skey = sc->sense_buffer[2] & 0x0F; in mptscsih_info_scsiio() 555 asc = sc->sense_buffer[12]; in mptscsih_info_scsiio() 556 ascq = sc->sense_buffer[13]; in mptscsih_info_scsiio() 902 (sc->sense_buffer[2] & 0x20)) { in mptscsih_io_done() 905 sc->sense_buffer[3] << 24 | in mptscsih_io_done() 906 sc->sense_buffer[4] << 16 | in mptscsih_io_done() 907 sc->sense_buffer[5] << 8 | in mptscsih_io_done() 908 sc->sense_buffer[6]; in mptscsih_io_done() 909 if (((sc->sense_buffer[3] & 0x80) == in mptscsih_io_done() 912 sc->sense_buffer[2] = in mptscsih_io_done() [all …]
|
/drivers/scsi/aacraid/ |
D | aachba.c | 1124 memcpy(cmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in aac_bounds_32() 1844 memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in io_callback() 1858 memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in io_callback() 1934 memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in aac_read() 2028 memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in aac_write() 2097 memcpy(cmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in synchronize_callback() 2385 memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data, in aac_scsi_cmd() 2449 memcpy(scsicmd->sense_buffer, in aac_scsi_cmd() 2718 memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data, sizeof (struct sense_data)); in aac_scsi_cmd() 2744 memcpy(scsicmd->sense_buffer, in aac_scsi_cmd() [all …]
|
/drivers/ata/ |
D | libata-scsi.c | 283 scsi_build_sense_buffer(d_sense, cmd->sense_buffer, sk, asc, ascq); in ata_scsi_set_sense() 299 scsi_set_sense_information(cmd->sense_buffer, in ata_scsi_set_sense_information() 308 scsi_set_sense_field_pointer(cmd->sense_buffer, SCSI_SENSE_BUFFERSIZE, in ata_scsi_set_invalid_field() 317 scsi_set_sense_field_pointer(cmd->sense_buffer, SCSI_SENSE_BUFFERSIZE, in ata_scsi_set_invalid_parameter() 1021 unsigned char *sb = cmd->sense_buffer; in ata_gen_passthru_sense() 1044 scsi_build_sense_buffer(1, cmd->sense_buffer, in ata_gen_passthru_sense() 1048 if ((cmd->sense_buffer[0] & 0x7f) >= 0x72) { in ata_gen_passthru_sense() 1120 unsigned char *sb = cmd->sense_buffer; in ata_gen_ata_sense() 2752 memset(cmd->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); in atapi_request_sense() 2760 cmd->sense_buffer[0] = 0x70; in atapi_request_sense() [all …]
|
/drivers/scsi/lpfc/ |
D | lpfc_scsi.c | 3006 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in lpfc_calc_bg_err() 3017 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in lpfc_calc_bg_err() 3029 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in lpfc_calc_bg_err() 3113 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in lpfc_parse_bg_err() 3129 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in lpfc_parse_bg_err() 3146 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in lpfc_parse_bg_err() 3167 cmd->sense_buffer[7] = 0xc; /* Additional sense length */ in lpfc_parse_bg_err() 3168 cmd->sense_buffer[8] = 0; /* Information descriptor type */ in lpfc_parse_bg_err() 3169 cmd->sense_buffer[9] = 0xa; /* Additional descriptor length */ in lpfc_parse_bg_err() 3170 cmd->sense_buffer[10] = 0x80; /* Validity bit */ in lpfc_parse_bg_err() [all …]
|
/drivers/target/ |
D | target_core_xcopy.c | 356 unsigned char sense_buffer[TRANSPORT_SENSE_BUFFER]; member 659 DMA_FROM_DEVICE, 0, &xpt_cmd->sense_buffer[0]); in target_xcopy_read_source() 721 DMA_TO_DEVICE, 0, &xpt_cmd->sense_buffer[0]); in target_xcopy_write_destination()
|
D | target_core_pscsi.c | 601 unsigned char *sense_buffer) in pscsi_transport_complete() argument 690 if (sense_buffer && (status_byte(result) & CHECK_CONDITION)) { in pscsi_transport_complete() 691 memcpy(sense_buffer, pt->pscsi_sense, TRANSPORT_SENSE_BUFFER); in pscsi_transport_complete()
|
/drivers/s390/scsi/ |
D | zfcp_fc.h | 272 memcpy(scsi->sense_buffer, sense, sense_len); in zfcp_fc_eval_fcp_rsp()
|
/drivers/scsi/qla2xxx/ |
D | qla_isr.c | 1736 SET_CMD_SENSE_PTR(sp, cp->sense_buffer); in qla2x00_handle_sense() 1742 memcpy(cp->sense_buffer, sense_data, sense_len); in qla2x00_handle_sense() 1744 SET_CMD_SENSE_PTR(sp, cp->sense_buffer + sense_len); in qla2x00_handle_sense() 1759 cp->sense_buffer, sense_len); in qla2x00_handle_sense() 1866 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in qla2x00_handle_dif_error() 1876 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in qla2x00_handle_dif_error() 1886 scsi_build_sense_buffer(1, cmd->sense_buffer, ILLEGAL_REQUEST, in qla2x00_handle_dif_error() 2250 memset(cp->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); in qla2x00_status_entry() 2322 memset(cp->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); in qla2x00_status_entry()
|
/drivers/target/loopback/ |
D | tcm_loop.c | 651 if (se_cmd->sense_buffer && in tcm_loop_queue_status() 655 memcpy(sc->sense_buffer, se_cmd->sense_buffer, in tcm_loop_queue_status()
|