linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH #upstream-fixes] libata-eh: fix slave link EH action mask handling
@ 2008-10-21  4:47 Tejun Heo
  2008-10-21  5:12 ` Tejun Heo
  2008-10-21 10:47 ` Sergei Shtylyov
  0 siblings, 2 replies; 6+ messages in thread
From: Tejun Heo @ 2008-10-21  4:47 UTC (permalink / raw)
  To: Jeff Garzik, IDE/ATA development list, stable

Slave link action mask is transferred to masater link and all the EH
actions are taken by the master link.  ata_eh_about_to_do() and
ata_eh_done() are called with ATA_EH_ALL_ACTIONS to clear the slave
link actions during transfer.  This always sets ATA_PFLAG_RECOVERED
flag causing spurious "EH complete" messages.

Don't set ATA_PFLAG_RECOVERED for slave link actions.

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

Index: work/drivers/ata/libata-eh.c
===================================================================
--- work.orig/drivers/ata/libata-eh.c
+++ work/drivers/ata/libata-eh.c
@@ -1206,7 +1206,10 @@ void ata_eh_about_to_do(struct ata_link
 
 	ata_eh_clear_action(link, dev, ehi, action);
 
-	if (!(ehc->i.flags & ATA_EHI_QUIET))
+	/* About to take EH action, set RECOVERED.  Ignore actions on
+	 * slave links as master will do them again.
+	 */
+	if (!(ehc->i.flags & ATA_EHI_QUIET) && link != ap->slave_link)
 		ap->pflags |= ATA_PFLAG_RECOVERED;
 
 	spin_unlock_irqrestore(ap->lock, flags);

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

end of thread, other threads:[~2008-10-23  0:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-21  4:47 [PATCH #upstream-fixes] libata-eh: fix slave link EH action mask handling Tejun Heo
2008-10-21  5:12 ` Tejun Heo
2008-10-21 17:00   ` [stable] " Greg KH
2008-10-21 10:47 ` Sergei Shtylyov
2008-10-21 11:37   ` [PATCH #upstream-fixes, UDPATED] " Tejun Heo
2008-10-23  0:40     ` 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).