/[rtmk]/rtmk/thread.c
ViewVC logotype

Diff of /rtmk/thread.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1.1.1 by jrydberg, Fri Dec 7 02:05:48 2001 UTC revision 1.2 by jrydberg, Mon Dec 10 20:51:04 2001 UTC
# Line 316  thread_select (struct processor *process Line 316  thread_select (struct processor *process
316    return thread;    return thread;
317  }  }
318    
 /* Dispatch THREAD that have been active or suspended.    
    This puts the thread on the run queue.  */  
   
 static void  
 thread_dispatch (struct thread *thread)  
 {  
   /* ??? check stuff.  */  
 #if 0  
   if (thread->swap_fn != 0)  
     thread->sched_state |= THREAD_STATE_SWAPPED;  
 #endif  
   
   add_thread_to_run_queue (thread);  
 }  
   
319  /* Called when the current thread is given a new stack.  */  /* Called when the current thread is given a new stack.  */
320    
321  static void  static void
# Line 539  thread_wakeup_generic (int event, bool o Line 524  thread_wakeup_generic (int event, bool o
524        if (thread->wait_event == event)        if (thread->wait_event == event)
525          {          {
526            trace_printf ("found waiting thread");            trace_printf ("found waiting thread");
   
527                        
528            queue_remove (&wait_queues [hash_index], thread,            queue_remove (&wait_queues [hash_index], thread,
529                          struct thread *, waitq);                          struct thread *, waitq);
# Line 582  thread_wakeup_one (int event) Line 566  thread_wakeup_one (int event)
566  }  }
567    
568    
569    /* Interrupt THREAD. Bring it back from waiting state.  */
570    
571    void
572    thread_interrupt (struct thread *thread)
573    {
574      clear_wait (thread, 0);
575    }
576    
577  /* Resume THREAD.  If suspend counter drops to zero, we resume  /* Resume THREAD.  If suspend counter drops to zero, we resume
578     execution of the thread and puts it on the run queue.  */     execution of the thread and puts it on the run queue.  */
579    

Legend:
Removed from v.1.1.1.1  
changed lines
  Added in v.1.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26