From: Paul Mundt <lethal@linux-sh.org>
To: Tejun Heo <htejun@gmail.com>
Cc: jeff@garzik.org, linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: libata reset-seq merge broke sata_sil on sh
Date: Fri, 11 May 2007 09:52:17 +0900 [thread overview]
Message-ID: <20070511005217.GA23186@linux-sh.org> (raw)
In-Reply-To: <4643196B.7070806@gmail.com>
On Thu, May 10, 2007 at 03:08:59PM +0200, Tejun Heo wrote:
> Paul Mundt wrote:
> > The detection is simply flaky after that point, however before the
> > current master it never hit the 35 second point (and thus never implied
> > that the link was down). I'll double check the bisect log to see if there
> > was anything beyond that that may have caused it.
> >
> > The -ENODEV at least implies that the SRST fails, so at least that's a
> > starting point.
>
> If prereset() fails to get the initial DRDY before 10secs, it assumes
> something went wrong and escalates to hardreset. sil family of
> controllers report 0xff status while the link is broken and it seems
> that your particular drive needs more than the current 150ms to recover
> phy link. It probably went unnoticed till now because the device was
> never hardreset before. If the diagnosis is correct, increasing the
> delay in hardreset should fix the problem. Well, let's see. :-)
>
Bumping the hardreset delay up does indeed fix it, I've had to bump it up
to 1200 before it started working (at 600 it still fails):
[ 0.967379] scsi0 : sata_sil
[ 0.970425] scsi1 : sata_sil
[ 0.973298] ata1: SATA max UDMA/100 cmd 0xfd000280 ctl 0xfd00028a bmdma 0xfd000200 irq 0
[ 0.981331] ata2: SATA max UDMA/100 cmd 0xfd0002c0 ctl 0xfd0002ca bmdma 0xfd000208 irq 0
[ 1.299353] ata1: device not ready (errno=-19), forcing hardreset
[ 2.817893] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[ 2.826284] ata1.00: ata_hpa_resize 1: sectors = 39070080, hpa_sectors = 39070080
[ 2.831052] ata1.00: ATA-5: HHD424020F7SV00, 00MLA0A5, max UDMA/100
[ 2.837548] ata1.00: 39070080 sectors, multi 0: LBA
[ 2.842702] ata1.00: applying bridge limits
[ 2.854162] ata1.00: ata_hpa_resize 1: sectors = 39070080, hpa_sectors = 39070080
[ 2.858938] ata1.00: configured for UDMA/100
[ 3.172602] ata2: SATA link down (SStatus 0 SControl 310)
[ 3.175736] scsi 0:0:0:0: Direct-Access ATA HHD424020F7SV00 00ML PQ: 0 ANSI: 5
I'm not sure if it matters or not, but this is an iVDR drive, so that
might also have additional implications.
--
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index 4595d1f..4dad3fd 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -3518,7 +3518,7 @@ int sata_std_hardreset(struct ata_port *ap, unsigned int *class,
}
/* wait a while before checking status, see SRST for more info */
- msleep(150);
+ msleep(1200);
rc = ata_wait_ready(ap, deadline);
/* link occupied, -ENODEV too is an error */
next prev parent reply other threads:[~2007-05-11 0:52 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-10 7:20 libata reset-seq merge broke sata_sil on sh Paul Mundt
2007-05-10 11:28 ` Tejun Heo
2007-05-10 11:53 ` Tejun Heo
2007-05-10 12:46 ` Paul Mundt
2007-05-10 13:08 ` Tejun Heo
2007-05-11 0:52 ` Paul Mundt [this message]
2007-05-11 9:39 ` Tejun Heo
2007-05-12 3:49 ` Paul Mundt
2007-05-16 0:30 ` Paul Mundt
2007-05-16 16:44 ` [PATCH] libata: implement ata_wait_after_reset() Tejun Heo
2007-05-17 0:50 ` Paul Mundt
2007-05-17 0:59 ` Paul Mundt
2007-05-19 15:54 ` Indan Zupancic
2007-05-19 18:23 ` Tejun Heo
2007-05-19 22:54 ` Indan Zupancic
2007-05-20 9:50 ` Tejun Heo
2007-05-20 13:26 ` Indan Zupancic
2007-05-20 17:09 ` Tejun Heo
2007-05-20 19:35 ` Indan Zupancic
2007-05-19 16:39 ` Indan Zupancic
2007-05-19 18:43 ` Tejun Heo
2007-05-19 19:04 ` Tejun Heo
2007-05-19 22:33 ` sd_resume redundant? [was: [PATCH] libata: implement ata_wait_after_reset()] Indan Zupancic
2007-05-20 9:54 ` Tejun Heo
2007-05-20 14:27 ` Indan Zupancic
2007-05-20 17:17 ` Tejun Heo
2007-05-20 19:47 ` Indan Zupancic
2007-05-21 6:02 ` [PATCH] libata: implement ata_wait_after_reset() Paul Mundt
2007-05-29 1:31 ` Jeff Garzik
2007-05-29 7:33 ` 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=20070511005217.GA23186@linux-sh.org \
--to=lethal@linux-sh.org \
--cc=htejun@gmail.com \
--cc=jeff@garzik.org \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@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).