NeKernel dev
|
USER_PROCESS helper class, which contains needed utilities for the scheduler. More...
#include <UserProcessScheduler.h>
Public Member Functions | |
STATIC Bool | Switch (HAL::StackFramePtr frame_ptr, PID new_pid) |
Does a context switch in a CPU. | |
STATIC Bool | CanBeScheduled (const USER_PROCESS &process) |
Check if process can be schedulded. | |
STATIC ErrorOr< PID > | TheCurrentPID () |
Current proccess id getter. | |
STATIC SizeT | StartScheduling () |
Start scheduling the current team. |
USER_PROCESS helper class, which contains needed utilities for the scheduler.
Bool Kernel::UserProcessHelper::CanBeScheduled | ( | const USER_PROCESS & | process | ) |
Check if process can be schedulded.
process | the process reference. |
true | can be schedulded. |
false | cannot be schedulded. |
SizeT Kernel::UserProcessHelper::StartScheduling | ( | ) |
Start scheduling the current team.
Bool Kernel::UserProcessHelper::Switch | ( | HAL::StackFramePtr | frame_ptr, |
PID | new_pid ) |
Does a context switch in a CPU.
the_stack | the stackframe of the running app. |
new_pid | the process's PID. |
Prepare task switch. ///
Rollback on fail. ///
Current proccess id getter.