linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH #upstream-fixes] libata: fix follow-up SRST failure path
@ 2009-07-08  3:16 Tejun Heo
  2009-07-15  2:43 ` Jeff Garzik
  0 siblings, 1 reply; 2+ messages in thread
From: Tejun Heo @ 2009-07-08  3:16 UTC (permalink / raw)
  To: Jeff Garzik, IDE/ATA development list, stable

ata_eh_reset() was missing error return handling after follow-up SRST
allowing EH to continue the normal probing path after reset failure.
This was discovered while testing new WD 2TB drives which take longer
than 10 secs to spin up and cause the first follow-up SRST to time
out.

Signed-off-by: Tejun Heo <tj@kernel.org>
---
 drivers/ata/libata-eh.c |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c
index 94919ad..d37808b 100644
--- a/drivers/ata/libata-eh.c
+++ b/drivers/ata/libata-eh.c
@@ -2517,6 +2517,10 @@ int ata_eh_reset(struct ata_link *link, int classify,
 
 			ata_eh_about_to_do(link, NULL, ATA_EH_RESET);
 			rc = ata_do_reset(link, reset, classes, deadline, true);
+			if (rc) {
+				failed_link = link;
+				goto fail;
+			}
 		}
 	} else {
 		if (verbose)

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH #upstream-fixes] libata: fix follow-up SRST failure path
  2009-07-08  3:16 [PATCH #upstream-fixes] libata: fix follow-up SRST failure path Tejun Heo
@ 2009-07-15  2:43 ` Jeff Garzik
  0 siblings, 0 replies; 2+ messages in thread
From: Jeff Garzik @ 2009-07-15  2:43 UTC (permalink / raw)
  To: Tejun Heo; +Cc: IDE/ATA development list, stable

Tejun Heo wrote:
> ata_eh_reset() was missing error return handling after follow-up SRST
> allowing EH to continue the normal probing path after reset failure.
> This was discovered while testing new WD 2TB drives which take longer
> than 10 secs to spin up and cause the first follow-up SRST to time
> out.
> 
> Signed-off-by: Tejun Heo <tj@kernel.org>
> ---
>  drivers/ata/libata-eh.c |    4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c
> index 94919ad..d37808b 100644
> --- a/drivers/ata/libata-eh.c
> +++ b/drivers/ata/libata-eh.c
> @@ -2517,6 +2517,10 @@ int ata_eh_reset(struct ata_link *link, int classify,
>  
>  			ata_eh_about_to_do(link, NULL, ATA_EH_RESET);
>  			rc = ata_do_reset(link, reset, classes, deadline, true);
> +			if (rc) {
> +				failed_link = link;
> +				goto fail;
> +			}
>  		}

applied



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-07-15  2:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-08  3:16 [PATCH #upstream-fixes] libata: fix follow-up SRST failure path Tejun Heo
2009-07-15  2:43 ` Jeff Garzik

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).