mirror of
https://gitlab.com/sortix/sortix.git
synced 2023-02-13 20:55:38 -05:00
Add GetKernelProcess function to scheduler.
This commit is contained in:
parent
193b76f8cb
commit
907acf1e18
2 changed files with 6 additions and 0 deletions
|
@ -55,6 +55,7 @@ void SetIdleThread(Thread* thread);
|
|||
void SetDummyThreadOwner(Process* process);
|
||||
void SetInitProcess(Process* init);
|
||||
Process* GetInitProcess();
|
||||
Process* GetKernelProcess();
|
||||
|
||||
} // namespace Scheduler
|
||||
|
||||
|
|
|
@ -225,6 +225,11 @@ Process* GetInitProcess()
|
|||
return initprocess;
|
||||
}
|
||||
|
||||
Process* GetKernelProcess()
|
||||
{
|
||||
return idlethread->process;
|
||||
}
|
||||
|
||||
void SetThreadState(Thread* thread, ThreadState state)
|
||||
{
|
||||
bool wasenabled = Interrupt::SetEnabled(false);
|
||||
|
|
Loading…
Add table
Reference in a new issue