Cleanup.
authorBen Pfaff <blp@cs.stanford.edu>
Tue, 21 Sep 2004 02:32:31 +0000 (02:32 +0000)
committerBen Pfaff <blp@cs.stanford.edu>
Tue, 21 Sep 2004 02:32:31 +0000 (02:32 +0000)
src/threads/thread.c

index b50eafe4f75e71280ebfd4b76b34fad1eebe4859..560423b7de39dd9f3c6d92efda1b4e23ce811b72 100644 (file)
@@ -69,15 +69,13 @@ thread_init (void)
   ASSERT (intr_get_level () == INTR_OFF);
 
   lock_init (&tid_lock, "tid");
+  list_init (&ready_list);
 
   /* Set up a thread structure for the running thread. */
   initial_thread = running_thread ();
   init_thread (initial_thread, "main", PRI_DEFAULT);
   initial_thread->status = THREAD_RUNNING;
   initial_thread->tid = allocate_tid ();
-
-  /* Initialize run queue. */
-  list_init (&ready_list);
 }
 
 /* Starts preemptive thread scheduling by enabling interrupts.