From: Jeff Garzik <jeff@garzik.org>
To: Tejun Heo <htejun@gmail.com>
Cc: Mark Lord <liml@rtr.ca>,
IDE/ATA development list <linux-ide@vger.kernel.org>,
Albert Lee <albertcc@tw.ibm.com>
Subject: Re: [PATCH] libata: make WARN_ON conditions in ata_sff_hsm_move() more strict
Date: Fri, 25 Apr 2008 00:47:41 -0400 [thread overview]
Message-ID: <4811626D.2010607@garzik.org> (raw)
In-Reply-To: <480F2214.1070807@gmail.com>
Tejun Heo wrote:
> WARN_ON()'s in ata_hsm_move() was too liberal and got triggerred when
> it shouldn't (e.g. hotplug events at the right moment). As the HSM
> only deals with device errors and state machine violations, make it
> check only against them.
>
> Signed-off-by: Tejun Heo <htejun@gmail.com>
> Cc: Mark Lord <liml@rtr.ca>
> Cc: Albert Lee <albertcc@tw.ibm.com>
> ---
> drivers/ata/libata-sff.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c
> index 1549952..2ec65a8 100644
> --- a/drivers/ata/libata-sff.c
> +++ b/drivers/ata/libata-sff.c
> @@ -1208,7 +1208,7 @@ fsm_start:
> DPRINTK("ata%u: dev %u command complete, drv_stat 0x%x\n",
> ap->print_id, qc->dev->devno, status);
>
> - WARN_ON(qc->err_mask);
> + WARN_ON(qc->err_mask & (AC_ERR_DEV | AC_ERR_HSM));
>
> ap->hsm_task_state = HSM_ST_IDLE;
>
> @@ -1222,7 +1222,7 @@ fsm_start:
> /* make sure qc->err_mask is available to
> * know what's wrong and recover
> */
> - WARN_ON(qc->err_mask == 0);
> + WARN_ON(!(qc->err_mask & (AC_ERR_DEV | AC_ERR_HSM)));
>
> ap->hsm_task_state = HSM_ST_IDLE;
applied
prev parent reply other threads:[~2008-04-25 4:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-23 11:48 [PATCH] libata: make WARN_ON conditions in ata_sff_hsm_move() more strict Tejun Heo
2008-04-25 4:47 ` Jeff Garzik [this message]
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=4811626D.2010607@garzik.org \
--to=jeff@garzik.org \
--cc=albertcc@tw.ibm.com \
--cc=htejun@gmail.com \
--cc=liml@rtr.ca \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.