Commit 914616a3 authored by Tejun Heo's avatar Tejun Heo Committed by Jeff Garzik

libata: fix infinite EH waiting bug

When EH gives up after repeated exceptions, it doesn't't clear the
PENDING bit on exit which leaves PENDING bit set without EH actually
scheduled.  This makes ata_port_wait_eh() to wait forever makes rmmod
hang on such port.  Fix it by clearing the flag.
Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
parent 09d7f9b0
...@@ -336,6 +336,7 @@ void ata_scsi_error(struct Scsi_Host *host) ...@@ -336,6 +336,7 @@ void ata_scsi_error(struct Scsi_Host *host)
} }
ata_port_printk(ap, KERN_ERR, "EH pending after %d " ata_port_printk(ap, KERN_ERR, "EH pending after %d "
"tries, giving up\n", ATA_EH_MAX_REPEAT); "tries, giving up\n", ATA_EH_MAX_REPEAT);
ap->pflags &= ~ATA_PFLAG_EH_PENDING;
} }
/* this run is complete, make sure EH info is clear */ /* this run is complete, make sure EH info is clear */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment