44 #define PORT_SUPPORTS_RT                FALSE    50 #define PORT_NATURAL_ALIGN              sizeof (void *)    56 #define PORT_STACK_ALIGN                sizeof (stkalign_t)    62 #define PORT_WORKING_AREA_ALIGN         sizeof (stkalign_t)    72 #define PORT_ARCHITECTURE_XXX    77 #define PORT_ARCHITECTURE_XXX_YYY    82 #define PORT_ARCHITECTURE_NAME          "XXX Architecture"    87 #if defined(__GNUC__) || defined(__DOXYGEN__)    88 #define PORT_COMPILER_NAME              "GCC " __VERSION__    91 #error "unsupported compiler"    97 #define PORT_INFO                       "no info"   110 #if !defined(PORT_IDLE_THREAD_STACK_SIZE) || defined(__DOXYGEN__)   111 #define PORT_IDLE_THREAD_STACK_SIZE     32   119 #if !defined(PORT_INT_REQUIRED_STACK) || defined(__DOXYGEN__)   120 #define PORT_INT_REQUIRED_STACK         256   129 #if !defined(PORT_USE_ALT_TIMER) || defined(__DOXYGEN__)   130 #define PORT_USE_ALT_TIMER              FALSE   136 #if !defined(PORT_XXX_WFI_SLEEP_IDLE) || defined(__DOXYGEN__)   137 #define PORT_XXX_ENABLE_WFI_IDLE      FALSE   150 #if !defined(_FROM_ASM_)   200 #define PORT_SETUP_CONTEXT(tp, wbase, wtop, pf, arg) {                      \   207 #define PORT_WA_SIZE(n) (sizeof(struct port_intctx) +                       \   208                          sizeof(struct port_extctx) +                       \   209                          ((size_t)(n)) + ((size_t)(PORT_INT_REQUIRED_STACK)))   219 #define PORT_WORKING_AREA(s, n)                                             \   220   stkalign_t s[THD_WORKING_AREA_SIZE(n) / sizeof (stkalign_t)]   225 #define PORT_IRQ_IS_VALID_PRIORITY(n) false   230 #define PORT_IRQ_IS_VALID_KERNEL_PRIORITY(n) false   237 #define PORT_IRQ_PROLOGUE()   244 #define PORT_IRQ_EPILOGUE()   251 #define PORT_IRQ_HANDLER(id) void id(void)   258 #define PORT_FAST_IRQ_HANDLER(id) void id(void)   270 #if !CH_DBG_ENABLE_STACK_CHECK || defined(__DOXYGEN__)   271 #define port_switch(ntp, otp) _port_switch(ntp, otp)   273 #define port_switch(ntp, otp) {                                             \   274   register struct port_intctx *sp asm ("%r1");                              \   275   if ((stkalign_t *)(sp - 1) < otp->wabase)                                 \   276     chSysHalt("stack overflow");                                            \   277   _port_switch(ntp, otp);                                                   \   287 #if !defined(_FROM_ASM_)   306 #if !defined(_FROM_ASM_)   416 #if PORT_XXX_ENABLE_WFI_IDLE   438 #if !defined(_FROM_ASM_)   440 #if CH_CFG_ST_TIMEDELTA > 0   441 #if !PORT_USE_ALT_TIMER   442 #include "chcore_timer.h"   444 #include "chcore_timer_alt.h" static void port_wait_for_interrupt(void)
Enters an architecture-dependent IRQ-waiting mode. 
 
static void port_enable(void)
Enables all the interrupt sources. 
 
void _port_init(void)
Port-related initialization code. 
 
static rtcnt_t port_rt_get_counter_value(void)
Returns the current value of the realtime counter. 
 
Platform dependent part of the thread_t structure. 
 
static void port_disable(void)
Disables all the interrupt sources. 
 
static void port_unlock(void)
Kernel-unlock action. 
 
static void port_lock_from_isr(void)
Kernel-lock action from an interrupt handler. 
 
void _port_switch(thread_t *ntp, thread_t *otp)
Performs a context switch between two threads. 
 
static bool port_is_isr_context(void)
Determines the current execution context. 
 
static void port_lock(void)
Kernel-lock action. 
 
uint64_t stkalign_t
Type of stack and memory alignment enforcement. 
 
static void port_unlock_from_isr(void)
Kernel-unlock action from an interrupt handler. 
 
static syssts_t port_get_irq_status(void)
Returns a word encoding the current interrupts status. 
 
static void port_suspend(void)
Disables the interrupt sources below kernel-level priority. 
 
static bool port_irq_enabled(syssts_t sts)
Checks the interrupt status. 
 
Structure representing a thread.