Functions | |
uint32_t | os_dispatch_system_call (uint32_t LR) |
ARM-specific entrypoint for system call handlers. | |
void | SVC_Handler (void) |
void | os_core_sleep (void) |
Park current core This function is free to park current core in whatever way that will still allow the core to be woken up by external interrupts. | |
static unsigned | os_exception_frame_size (bool fp_used) |
ExceptionFrame * | push_exception_frame (ExceptionFrame *frame, unsigned args, bool fp_active) |
Duplicate exception frame on thread's stack. | |
ExceptionFrame * | shim_exception_frame (ExceptionFrame *frame, unsigned args, bool fp_active) |
Creates space for additional arguments under exception frame. | |
ExceptionFrame * | pop_exception_frame (ExceptionFrame *frame, unsigned args, bool fp_active) |
Remove exception frame from thread's stack. | |
Variables | |
static SYSCALL_DEFINITION struct Syscall_Entry_t | nvic_syscalls [] |
void os_core_sleep | ( | void | ) |
Park current core This function is free to park current core in whatever way that will still allow the core to be woken up by external interrupts.
uint32_t os_dispatch_system_call | ( | uint32_t | LR | ) |
ARM-specific entrypoint for system call handlers.
This routine is common entrypoint for all syscall routines. It decodes the syscall ID requested by userspace application and calls generic method to service the system call. It is callable by executing the SVC instruction. Code of SVC_Handler will retrieve the requested SVC ID and let generic machinery to execute specified system call.
|
static |
ExceptionFrame * pop_exception_frame | ( | ExceptionFrame * | frame, |
unsigned | args, | ||
bool | fp_active | ||
) |
Remove exception frame from thread's stack.
This function will revert effects of calling push_exception_frame. It will handle frame padding automatically.
frame | exception frame base address |
args | number of function arguments passed onto stack (function args - 4) |
fp_active | if true then floating point unit is actively used in the thread exception is for |
ExceptionFrame * push_exception_frame | ( | ExceptionFrame * | frame, |
unsigned | args, | ||
bool | fp_active | ||
) |
Duplicate exception frame on thread's stack.
frame | pointer of frame currently residing on top of process' stack |
args | amount of arguments pushed onto stack (first four come into R0-R3, fifth and following are pushed onto stack) |
fp_active | if true then floating point unit is actively used in the thread exception is for |
ExceptionFrame * shim_exception_frame | ( | ExceptionFrame * | frame, |
unsigned | args, | ||
bool | fp_active | ||
) |
Creates space for additional arguments under exception frame.
This function will move exception frame content args * 4 bytes lower. If resulting address won't be 8-byt aligned, then additional alignment is applied to it. Content of exception frame is copied automatically.
frame | address of exception frame in memory |
args | amount of additional arguments for which space should be created under exception frame |
fp_active | if true then floating point unit is actively used in the thread exception is for |
void SVC_Handler | ( | void | ) |
|
static |