summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/libata-scsi.c
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2006-04-02 18:51:52 +0900
committerJeff Garzik <jeff@garzik.org>2006-04-02 10:09:19 -0400
commitc43c555c3a6db7f0b55fd9b66d7ecff16e827d4e (patch)
tree3036762ea56f742414eaaf098f9f5f34dedb03e4 /drivers/scsi/libata-scsi.c
parent5eb45c02a9944e813a0b82457607557a1f2c64b5 (diff)
downloadkernel-crypto-c43c555c3a6db7f0b55fd9b66d7ecff16e827d4e.tar.gz
kernel-crypto-c43c555c3a6db7f0b55fd9b66d7ecff16e827d4e.tar.xz
kernel-crypto-c43c555c3a6db7f0b55fd9b66d7ecff16e827d4e.zip
[PATCH] libata: ATA_FLAG_IN_EH is not used, kill it
Kill unused flag ATA_FLAG_IN_EH. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/scsi/libata-scsi.c')
-rw-r--r--drivers/scsi/libata-scsi.c17
1 files changed, 4 insertions, 13 deletions
diff --git a/drivers/scsi/libata-scsi.c b/drivers/scsi/libata-scsi.c
index c1a4b29a9ae..bcbf71e9895 100644
--- a/drivers/scsi/libata-scsi.c
+++ b/drivers/scsi/libata-scsi.c
@@ -779,20 +779,15 @@ enum scsi_eh_timer_return ata_scsi_timed_out(struct scsi_cmnd *cmd)
int ata_scsi_error(struct Scsi_Host *host)
{
- struct ata_port *ap;
- unsigned long flags;
+ struct ata_port *ap = (struct ata_port *)&host->hostdata[0];
DPRINTK("ENTER\n");
- ap = (struct ata_port *) &host->hostdata[0];
+ /* synchronize with IRQ handler and port task */
+ spin_unlock_wait(&ap->host_set->lock);
+ ata_port_flush_task(ap);
- spin_lock_irqsave(&ap->host_set->lock, flags);
- WARN_ON(ap->flags & ATA_FLAG_IN_EH);
- ap->flags |= ATA_FLAG_IN_EH;
WARN_ON(ata_qc_from_tag(ap, ap->active_tag) == NULL);
- spin_unlock_irqrestore(&ap->host_set->lock, flags);
-
- ata_port_flush_task(ap);
ap->ops->eng_timeout(ap);
@@ -800,10 +795,6 @@ int ata_scsi_error(struct Scsi_Host *host)
scsi_eh_flush_done_q(&ap->eh_done_q);
- spin_lock_irqsave(&ap->host_set->lock, flags);
- ap->flags &= ~ATA_FLAG_IN_EH;
- spin_unlock_irqrestore(&ap->host_set->lock, flags);
-
DPRINTK("EXIT\n");
return 0;
}