* [PATCH] libata: don't consider 0xff as port empty if SStatus is available
@ 2007-05-23 9:22 Tejun Heo
0 siblings, 0 replies; only message in thread
From: Tejun Heo @ 2007-05-23 9:22 UTC (permalink / raw)
To: Jeff Garzik, IDE/ATA development list; +Cc: Paul Mundt, Indan Zupancic
Some SATA controllers (sata_sil) use 0xff to indicate port not ready
status, not port empty. As libata interprets 0xff as port empty, this
causes unnecessary reset failure and retry. Don't consider 0xff as
port empty if SStatus is available and indicates that port is online.
Signed-off-by: tejun Heo <htejun@gmail.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Indan Zupancic <indan@nul.nu>
---
This one is for 2.6.22. Thanks.
libata-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index a6de57e..5788a9d 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -3022,7 +3022,7 @@ int ata_wait_ready(struct ata_port *ap,
if (!(status & ATA_BUSY))
return 0;
- if (status == 0xff)
+ if (!ata_port_online(ap) && status == 0xff)
return -ENODEV;
if (time_after(now, deadline))
return -EBUSY;
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2007-05-23 9:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-23 9:22 [PATCH] libata: don't consider 0xff as port empty if SStatus is available Tejun Heo
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).