Skip to content

Commit

Permalink
libata-eh: fix slave link EH action mask handling
Browse files Browse the repository at this point in the history
Slave link action mask is transferred to master 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>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
  • Loading branch information
htejun authored and Jeff Garzik committed Oct 23, 2008
1 parent 848e4c6 commit a568d1d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion drivers/ata/libata-eh.c
Original file line number Diff line number Diff line change
Expand Up @@ -1206,7 +1206,10 @@ void ata_eh_about_to_do(struct ata_link *link, struct ata_device *dev,

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);
Expand Down

0 comments on commit a568d1d

Please sign in to comment.