/branches/arm/uspace/libc/arch/arm32/include/psthread.h |
---|
44,8 → 44,13 |
#define STACK_ALIGNMENT 8 |
#define SP_DELTA (0 + ALIGN_UP(STACK_ITEM_SIZE, STACK_ALIGNMENT)) |
//TODO: check if correct |
#define context_set(c, _pc, stack, size, ptls) \ |
(c)->pc = (sysarg_t) (_pc); \ |
(c)->sp = ((sysarg_t) (stack)) + (size) - SP_DELTA; \ |
(c)->tls = ((sysarg_t)(ptls)) + sizeof(tcb_t); |
typedef struct { |
uint32_t sp; |
uint32_t pc; |
59,6 → 64,7 |
uint32_t r11; |
} context_t; |
#endif |
/** @} |