1 #ifndef SPARC32_CONTEXT_H
2 #define SPARC32_CONTEXT_H
5 /* General registers */
11 #define SP_LOC(ctx) (&(ctx)->regs[REG_SP])
13 /* Optional stack contents */
18 /* Create a new context in the given stack */
20 init_context(uint8_t *stack, uint32_t stack_size, int num_param);
23 struct context *switch_to(struct context *);
25 /* Holds physical address of boot context */
26 extern unsigned long __boot_ctx;
28 /* This can always be safely used to refer to the boot context */
29 #define boot_ctx ((struct context *) phys_to_virt(__boot_ctx))
31 #endif /* SPARC32_CONTEXT_H */