/* * Shut down the other threads in the thread system when a panic occurs. */ void thread_panic(void) { assert(curspl > 0); thread_killall(); scheduler_killall(); }
/* * Cleanup function. * * The queue objects to being destroyed if it's got stuff in it. * Use scheduler_killall to make sure this is the case. During * ordinary shutdown, normally it should be. */ void scheduler_shutdown(void) { scheduler_killall(); assert(curspl>0); q_destroy(runqueue); runqueue = NULL; }
/* * Cleanup function. * * The queue objects to being destroyed if it's got stuff in it. * Use scheduler_killall to make sure this is the case. During * ordinary shutdown, normally it should be. */ void scheduler_shutdown(void) { panic("not used."); scheduler_killall(); assert(curspl>0); q_destroy(runqueue); runqueue = NULL; }
void scheduler_shutdown(void) { int i; scheduler_killall(); assert(curspl>0); for(i = 0; i < NUM_PRIORITIES; i++) { q_destroy(runqueue[i]); runqueue[i] = NULL; } }