Kernel: Use a WaitQueue to implement finalizer wakeup

This gets rid of the special "Lurking" thread state and replaces it
with a generic WaitQueue :^)
This commit is contained in:
Andreas Kling 2019-12-01 19:17:17 +01:00
commit 8bb98aa31b
Notes: sideshowbarker 2024-07-19 11:00:18 +09:00
5 changed files with 9 additions and 9 deletions

View file

@ -661,6 +661,9 @@ void Thread::set_state(State new_state)
if (m_process.pid() != 0) {
Scheduler::update_state_for_thread(*this);
}
if (new_state == Dying)
g_finalizer_wait_queue->wake_all();
}
String Thread::backtrace(ProcessInspectionHandle&) const