From: Tejun Heo <htejun@gmail.com>
To: jgarzik@pobox.com, alan@lxorguk.ukuu.org.uk, albertcc@tw.ibm.com,
linux-ide@vger.kernel.org
Cc: Tejun Heo <htejun@gmail.com>
Subject: [PATCH 03/15] libata: ATA_FLAG_IN_EH is not used, kill it
Date: Sun, 2 Apr 2006 18:51:52 +0900 [thread overview]
Message-ID: <11439715122600-git-send-email-htejun@gmail.com> (raw)
In-Reply-To: <11439715124131-git-send-email-htejun@gmail.com>
Kill unused flag ATA_FLAG_IN_EH.
Signed-off-by: Tejun Heo <htejun@gmail.com>
---
drivers/scsi/libata-scsi.c | 17 ++++-------------
include/linux/libata.h | 1 -
2 files changed, 4 insertions(+), 14 deletions(-)
ba36d3e3f4b1dba269a1c09f48f3131d287181ca
diff --git a/drivers/scsi/libata-scsi.c b/drivers/scsi/libata-scsi.c
index c1a4b29..bcbf71e 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
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 *hos
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;
}
diff --git a/include/linux/libata.h b/include/linux/libata.h
index a4a1e63..e20b0bf 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -152,7 +152,6 @@ enum {
ATA_FLAG_IRQ_MASK = (1 << 14), /* Mask IRQ in PIO xfers */
ATA_FLAG_FLUSH_PORT_TASK = (1 << 15), /* Flush port task */
- ATA_FLAG_IN_EH = (1 << 16), /* EH in progress */
ATA_QCFLAG_ACTIVE = (1 << 1), /* cmd not yet ack'd to scsi lyer */
ATA_QCFLAG_SG = (1 << 3), /* have s/g table? */
--
1.2.4
next prev parent reply other threads:[~2006-04-02 9:51 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-02 9:51 [PATCHSET] libata: prep for new EH, take 2 Tejun Heo
2006-04-02 9:51 ` [PATCH 02/15] libata: ata_dev_revalidate() printk update Tejun Heo
2006-04-02 9:51 ` Tejun Heo [this message]
2006-04-02 9:51 ` [PATCH 05/15] libata: rename ATA_FLAG_PORT_DISABLED to ATA_FLAG_DISABLED Tejun Heo
2006-04-02 9:51 ` [PATCH 04/15] libata: clean up constants Tejun Heo
2006-04-02 9:51 ` [PATCH 01/15] libata: report device number when PIO fails Tejun Heo
2006-04-02 9:51 ` [PATCH 11/15] libata: don't read TF directly from sense generation functions Tejun Heo
2006-04-02 9:51 ` [PATCH 07/15] libata: clear ATA_DFLAG_PIO before setting it Tejun Heo
2006-04-02 9:51 ` [PATCH 13/15] libata: dec scmd->retries for qcs with zero err_mask Tejun Heo
2006-04-02 9:51 ` [PATCH 12/15] libata: add @cdb to ata_exec_internal() Tejun Heo
2006-04-02 9:51 ` [PATCH 06/15] libata: clear only affected flags during ata_dev_configure() Tejun Heo
2006-04-02 9:51 ` [PATCH 15/15] libata: make some libata-core routines extern Tejun Heo
2006-04-02 9:51 ` [PATCH 14/15] libata: separate out libata-eh.c Tejun Heo
2006-04-02 9:51 ` [PATCH 08/15] libata: add ATA_QCFLAG_IO Tejun Heo
2006-04-02 9:51 ` [PATCH 10/15] libata: always generate sense if qc->err_mask is non-zero Tejun Heo
2006-04-02 9:51 ` [PATCH 09/15] libata: pass qc around intead of ap during PIO Tejun Heo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=11439715122600-git-send-email-htejun@gmail.com \
--to=htejun@gmail.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=albertcc@tw.ibm.com \
--cc=jgarzik@pobox.com \
--cc=linux-ide@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).