]> Devi Nivas Git - cs3210-lab1.git/commitdiff
move ide_intr lower
authorrsc <rsc>
Fri, 8 Sep 2006 14:33:27 +0000 (14:33 +0000)
committerrsc <rsc>
Fri, 8 Sep 2006 14:33:27 +0000 (14:33 +0000)
ide.c

diff --git a/ide.c b/ide.c
index 3f6f5c81bde2fdfa06086be5a4d1b9906d89c14a..ebb561ad7f89080d41a42ec566bb84db3992cc0e 100644 (file)
--- a/ide.c
+++ b/ide.c
@@ -64,15 +64,6 @@ ide_init(void)
   disk_1_present = ide_probe_disk1();
 }
 
-// Interrupt handler - wake up the request that just finished.
-void
-ide_intr(void)
-{
-  acquire(&ide_lock);
-  wakeup(&request[tail]);
-  release(&ide_lock);
-}
-
 // Probe to see if disk 1 exists (we assume disk 0 exists).
 static int
 ide_probe_disk1(void)
@@ -95,6 +86,15 @@ ide_probe_disk1(void)
   return x < 1000;
 }
 
+// Interrupt handler - wake up the request that just finished.
+void
+ide_intr(void)
+{
+  acquire(&ide_lock);
+  wakeup(&request[tail]);
+  release(&ide_lock);
+}
+
 // Start the next request in the queue.
 static void
 ide_start_request (void)