Subversion Repositories HelenOS-historic

Rev

Rev 402 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 402 Rev 403
Line 47... Line 47...
47
#undef context_set
47
#undef context_set
48
#endif
48
#endif
49
 
49
 
50
#define context_set(c, _pc, stack, size)                        \
50
#define context_set(c, _pc, stack, size)                        \
51
    (c)->pc = (__address) _pc;                          \
51
    (c)->pc = (__address) _pc;                          \
52
    (c)->bsp = ((__address) stack) + (ALIGN(sizeof(the_t), STACK_ALIGNMENT));   \
52
    (c)->bsp = ((__address) stack) + ALIGN(sizeof(the_t), STACK_ALIGNMENT);     \
53
    (c)->sp = ((__address) stack) + (size) - SP_DELTA;
53
    (c)->sp = ((__address) stack) + ALIGN((size) - SP_DELTA, STACK_ALIGNMENT);
54
 
54
 
55
/*
55
/*
56
 * Only save registers that must be preserved across
56
 * Only save registers that must be preserved across
57
 * function calls.
57
 * function calls.
58
 */
58
 */