kernel.h¶
Defines
-
EMB_INIT_TABLE_ENTRY(fn)¶
-
EMB_CHECK(expr)¶
EMB_CHECK() - Fault on a status other than EMB_OK in checked builds.
In a release build the macro is the expression’s value. SPEC-001 §13.
Functions
-
void emb_kernel_init(void)¶
emb_kernel_init() - Initialize the kernel and run the initialization table.
Must be the first kernel call; calls emb_arch_init(). Objects defined with EMB_*_DEFINE are constructed here, in link order.
Context: prekernel Blocking: no Timing: O(init table) Ownership: none Configuration: Requirements: KRN-OBJ-009 KRN-THR-007 Since: 0.2 Stability: yes
-
void emb_kernel_start(void)¶
emb_kernel_start() - Launch the first thread; never returns.
Preemption point P3 (SPEC-002 §6.1). Threads started before this call run now, highest priority first. The pre-kernel stack becomes the interrupt stack or the idle context’s stack per port (SPEC-008 §10).
Context: prekernel Blocking: no Timing: O(1) Ownership: none Configuration: Requirements: KRN-IRQ-023 KRN-THR-016 Since: 0.2 Stability: yes
-
emb_status_t emb_check_status(emb_status_t status, const char *what)¶
emb_check_status() - The function behind EMB_CHECK()
.
Context: thread isr prekernel Blocking: no Timing: O(1) Ownership: none Configuration: CONFIG_EMB_CHECKED Requirements: API-015 API-017 Since: 0.2 Stability: yes
Return:
statuswhen it is EMB_OK; otherwise raises EMB_FAULT_CHECK and does not return.- Parameters:
status – The value to check.
what – The checked expression, for the crash record.
-
struct emb_init_entry¶
- #include <kernel.h>
Public Members