kernel: fix some uses of disable_count

This commit is contained in:
Liam 2022-06-15 20:53:49 -04:00
parent f86b770ff7
commit 744a208763
4 changed files with 7 additions and 14 deletions

View file

@ -225,7 +225,7 @@ ResultCode KThread::Initialize(KThreadFunction func, uintptr_t arg, VAddr user_s
// Setup the stack parameters.
StackParameters& sp = GetStackParameters();
sp.cur_thread = this;
sp.disable_count = 0;
sp.disable_count = 1;
SetInExceptionHandler();
// Set thread ID.
@ -1014,8 +1014,6 @@ ResultCode KThread::Run() {
// Set our state and finish.
SetState(ThreadState::Runnable);
DisableDispatch();
return ResultSuccess;
}
}