aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata/libata-eh.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ata/libata-eh.c')
-rw-r--r--drivers/ata/libata-eh.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c
index f2dd99122bd6..a93247cc395a 100644
--- a/drivers/ata/libata-eh.c
+++ b/drivers/ata/libata-eh.c
@@ -33,6 +33,7 @@
33 */ 33 */
34 34
35#include <linux/kernel.h> 35#include <linux/kernel.h>
36#include <linux/blkdev.h>
36#include <linux/pci.h> 37#include <linux/pci.h>
37#include <scsi/scsi.h> 38#include <scsi/scsi.h>
38#include <scsi/scsi_host.h> 39#include <scsi/scsi_host.h>
@@ -459,29 +460,29 @@ static void ata_eh_clear_action(struct ata_link *link, struct ata_device *dev,
459 * RETURNS: 460 * RETURNS:
460 * EH_HANDLED or EH_NOT_HANDLED 461 * EH_HANDLED or EH_NOT_HANDLED
461 */ 462 */
462enum scsi_eh_timer_return ata_scsi_timed_out(struct scsi_cmnd *cmd) 463enum blk_eh_timer_return ata_scsi_timed_out(struct scsi_cmnd *cmd)
463{ 464{
464 struct Scsi_Host *host = cmd->device->host; 465 struct Scsi_Host *host = cmd->device->host;
465 struct ata_port *ap = ata_shost_to_port(host); 466 struct ata_port *ap = ata_shost_to_port(host);
466 unsigned long flags; 467 unsigned long flags;
467 struct ata_queued_cmd *qc; 468 struct ata_queued_cmd *qc;
468 enum scsi_eh_timer_return ret; 469 enum blk_eh_timer_return ret;
469 470
470 DPRINTK("ENTER\n"); 471 DPRINTK("ENTER\n");
471 472
472 if (ap->ops->error_handler) { 473 if (ap->ops->error_handler) {
473 ret = EH_NOT_HANDLED; 474 ret = BLK_EH_NOT_HANDLED;
474 goto out; 475 goto out;
475 } 476 }
476 477
477 ret = EH_HANDLED; 478 ret = BLK_EH_HANDLED;
478 spin_lock_irqsave(ap->lock, flags); 479 spin_lock_irqsave(ap->lock, flags);
479 qc = ata_qc_from_tag(ap, ap->link.active_tag); 480 qc = ata_qc_from_tag(ap, ap->link.active_tag);
480 if (qc) { 481 if (qc) {
481 WARN_ON(qc->scsicmd != cmd); 482 WARN_ON(qc->scsicmd != cmd);
482 qc->flags |= ATA_QCFLAG_EH_SCHEDULED; 483 qc->flags |= ATA_QCFLAG_EH_SCHEDULED;
483 qc->err_mask |= AC_ERR_TIMEOUT; 484 qc->err_mask |= AC_ERR_TIMEOUT;
484 ret = EH_NOT_HANDLED; 485 ret = BLK_EH_NOT_HANDLED;
485 } 486 }
486 spin_unlock_irqrestore(ap->lock, flags); 487 spin_unlock_irqrestore(ap->lock, flags);
487 488
@@ -833,7 +834,7 @@ void ata_qc_schedule_eh(struct ata_queued_cmd *qc)
833 * Note that ATA_QCFLAG_FAILED is unconditionally set after 834 * Note that ATA_QCFLAG_FAILED is unconditionally set after
834 * this function completes. 835 * this function completes.
835 */ 836 */
836 scsi_req_abort_cmd(qc->scsicmd); 837 blk_abort_request(qc->scsicmd->request);
837} 838}
838 839
839/** 840/**