aboutsummaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorSøren Schmidt <sos@FreeBSD.org>2006-04-14 16:25:42 +0000
committerSøren Schmidt <sos@FreeBSD.org>2006-04-14 16:25:42 +0000
commit3559734ceeb3176b949ac185ec2a5f4656172be0 (patch)
tree48fd3bd5751fe88e821d2660930bda425d9b82d4 /sys/dev
parentbc971e44ede92cfc725c8e57eb81390b647564f4 (diff)
Notes
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/ata/ata-all.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/ata/ata-all.c b/sys/dev/ata/ata-all.c
index b68cbe9592210..e9cffe173a7e3 100644
--- a/sys/dev/ata/ata-all.c
+++ b/sys/dev/ata/ata-all.c
@@ -277,8 +277,8 @@ ata_suspend(device_t dev)
if (!dev || !(ch = device_get_softc(dev)))
return ENXIO;
- /* wait for the channel to be IDLE before entering suspend mode */
- while (1) {
+ /* wait for the channel to be IDLE or detached before suspending */
+ while (ch->r_irq) {
mtx_lock(&ch->state_mtx);
if (ch->state == ATA_IDLE) {
ch->state = ATA_ACTIVE;