More info: ATA hang on resume (fwd)

Randy Bush randy at psg.com
Wed Dec 31 07:05:57 PST 2003


sad to say, the appended patch did NOT fix the problem i
have with resume on a thinkpad t40p

randy

---

--- ata-all.c.orig	Mon Dec  1 20:24:13 2003
+++ ata-all.c	Thu Dec 25 00:00:44 2003
@@ -230,6 +230,7 @@
 int
 ata_reinit(struct ata_channel *ch)
 {
+    int i;
     struct ata_request *request = ch->running;
     int devices, misdev, newdev;
     
@@ -241,7 +242,11 @@
     ATA_FORCELOCK_CH(ch, ATA_CONTROL);
     ch->running = NULL;
     devices = ch->devices;
-    ch->hw.reset(ch);
+    for (i=0; i < 10; i++) {
+        ch->hw.reset(ch);
+        if (devices == ch->devices)
+            break;
+    }
     ATA_UNLOCK_CH(ch);
 
     /* detach what left the channel during reset */



More information about the freebsd-current mailing list