libata-eh.c (0c49cd295d42d0032af11d55e2140dbec11dc8d0) | libata-eh.c (a13b0c9d09157e331b31e25c1ea19216b837a619) |
---|---|
1/* 2 * libata-eh.c - libata error handling 3 * 4 * Maintained by: Tejun Heo <tj@kernel.org> 5 * Please ALWAYS copy linux-ide@vger.kernel.org 6 * on emails. 7 * 8 * Copyright 2006 Tejun Heo <htejun@gmail.com> --- 2467 unchanged lines hidden (view full) --- 2476 ehc->i.serror & SERR_TRANS_ST_ERROR ? "TrStaTrns " : "", 2477 ehc->i.serror & SERR_UNRECOG_FIS ? "UnrecFIS " : "", 2478 ehc->i.serror & SERR_DEV_XCHG ? "DevExch " : ""); 2479#endif 2480 2481 for (tag = 0; tag < ATA_MAX_QUEUE; tag++) { 2482 struct ata_queued_cmd *qc = __ata_qc_from_tag(ap, tag); 2483 struct ata_taskfile *cmd = &qc->tf, *res = &qc->result_tf; | 1/* 2 * libata-eh.c - libata error handling 3 * 4 * Maintained by: Tejun Heo <tj@kernel.org> 5 * Please ALWAYS copy linux-ide@vger.kernel.org 6 * on emails. 7 * 8 * Copyright 2006 Tejun Heo <htejun@gmail.com> --- 2467 unchanged lines hidden (view full) --- 2476 ehc->i.serror & SERR_TRANS_ST_ERROR ? "TrStaTrns " : "", 2477 ehc->i.serror & SERR_UNRECOG_FIS ? "UnrecFIS " : "", 2478 ehc->i.serror & SERR_DEV_XCHG ? "DevExch " : ""); 2479#endif 2480 2481 for (tag = 0; tag < ATA_MAX_QUEUE; tag++) { 2482 struct ata_queued_cmd *qc = __ata_qc_from_tag(ap, tag); 2483 struct ata_taskfile *cmd = &qc->tf, *res = &qc->result_tf; |
2484 const u8 *cdb = qc->cdb; | |
2485 char data_buf[20] = ""; 2486 char cdb_buf[70] = ""; 2487 2488 if (!(qc->flags & ATA_QCFLAG_FAILED) || 2489 ata_dev_phys_link(qc->dev) != link || !qc->err_mask) 2490 continue; 2491 2492 if (qc->dma_dir != DMA_NONE) { --- 11 unchanged lines hidden (view full) --- 2504 }; 2505 2506 snprintf(data_buf, sizeof(data_buf), " %s %u %s", 2507 prot_str[qc->tf.protocol], qc->nbytes, 2508 dma_str[qc->dma_dir]); 2509 } 2510 2511 if (ata_is_atapi(qc->tf.protocol)) { | 2484 char data_buf[20] = ""; 2485 char cdb_buf[70] = ""; 2486 2487 if (!(qc->flags & ATA_QCFLAG_FAILED) || 2488 ata_dev_phys_link(qc->dev) != link || !qc->err_mask) 2489 continue; 2490 2491 if (qc->dma_dir != DMA_NONE) { --- 11 unchanged lines hidden (view full) --- 2503 }; 2504 2505 snprintf(data_buf, sizeof(data_buf), " %s %u %s", 2506 prot_str[qc->tf.protocol], qc->nbytes, 2507 dma_str[qc->dma_dir]); 2508 } 2509 2510 if (ata_is_atapi(qc->tf.protocol)) { |
2512 if (qc->scsicmd) 2513 scsi_print_command(qc->scsicmd); 2514 else 2515 snprintf(cdb_buf, sizeof(cdb_buf), 2516 "cdb %02x %02x %02x %02x %02x %02x %02x %02x " 2517 "%02x %02x %02x %02x %02x %02x %02x %02x\n ", 2518 cdb[0], cdb[1], cdb[2], cdb[3], 2519 cdb[4], cdb[5], cdb[6], cdb[7], 2520 cdb[8], cdb[9], cdb[10], cdb[11], 2521 cdb[12], cdb[13], cdb[14], cdb[15]); | 2511 const u8 *cdb = qc->cdb; 2512 size_t cdb_len = qc->dev->cdb_len; 2513 2514 if (qc->scsicmd) { 2515 cdb = qc->scsicmd->cmnd; 2516 cdb_len = qc->scsicmd->cmd_len; 2517 } 2518 __scsi_format_command(cdb_buf, sizeof(cdb_buf), 2519 cdb, cdb_len); |
2522 } else { 2523 const char *descr = ata_get_cmd_descript(cmd->command); 2524 if (descr) 2525 ata_dev_err(qc->dev, "failed command: %s\n", 2526 descr); 2527 } 2528 2529 ata_dev_err(qc->dev, --- 1613 unchanged lines hidden --- | 2520 } else { 2521 const char *descr = ata_get_cmd_descript(cmd->command); 2522 if (descr) 2523 ata_dev_err(qc->dev, "failed command: %s\n", 2524 descr); 2525 } 2526 2527 ata_dev_err(qc->dev, --- 1613 unchanged lines hidden --- |