PUSH_CALL_FRAME(): Renamed from PUSH_CALL_CONTEXT().
authorbernie <bernie@38d2e660-2303-0410-9eaa-f027e97ec537>
Sun, 10 Aug 2008 19:19:28 +0000 (19:19 +0000)
committerbernie <bernie@38d2e660-2303-0410-9eaa-f027e97ec537>
Sun, 10 Aug 2008 19:19:28 +0000 (19:19 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@1615 38d2e660-2303-0410-9eaa-f027e97ec537

bertos/cpu/attr.h
bertos/kern/proc.c

index 289869360294add9dbf0af54ca0ea0507c72ca03..c5f0201e6dde1b949209e26a67e0f0e9f6642906 100644 (file)
         * RTS discards SR while returning (it does not restore it). So we push
         * 0 to fake the same context.
         */
-       #define CPU_PUSH_CALL_CONTEXT(sp, func) \
+       #define CPU_PUSH_CALL_FRMAE(sp, func) \
                do { \
                        CPU_PUSH_WORD((sp), (func)); \
                        CPU_PUSH_WORD((sp), 0x100); \
         * memory accesses are big-endian (actually, it's a 8-bit CPU, so there is
         * no natural endianess).
         */
-       #define CPU_PUSH_CALL_CONTEXT(sp, func) \
+       #define CPU_PUSH_CALL_FRAME(sp, func) \
                do { \
                        uint16_t funcaddr = (uint16_t)(func); \
                        CPU_PUSH_WORD((sp), funcaddr); \
 
 #elif CPU_PPC
 
-       #define CPU_PUSH_CALL_CONTEXT(sp, func) \
+       #define CPU_PUSH_CALL_FRAME(sp, func) \
                do { \
                        CPU_PUSH_WORD((sp), (cpustack_t)(func)); /* LR -> 8(SP) */ \
                        CPU_PUSH_WORD((sp), 0);                  /* CR -> 4(SP) */ \
                } while (0)
 
 #else
-       #define CPU_PUSH_CALL_CONTEXT(sp, func) \
+       #define CPU_PUSH_CALL_FRAME(sp, func) \
                CPU_PUSH_WORD((sp), (cpustack_t)(func))
 #endif
 
index 5674038cae395e04fe2f6d677f96db0618c85c32..84c5366370911c10e61c3a5f1b2c8dd5397dfd9c 100644 (file)
@@ -221,8 +221,8 @@ struct Process *proc_new_with_name(UNUSED(const char *, name), void (*entry)(voi
 #endif
 
        /* Initialize process stack frame */
-       CPU_PUSH_CALL_CONTEXT(proc->stack, proc_exit);
-       CPU_PUSH_CALL_CONTEXT(proc->stack, entry);
+       CPU_PUSH_CALL_FRAME(proc->stack, proc_exit);
+       CPU_PUSH_CALL_FRAME(proc->stack, entry);
 
        /* Push a clean set of CPU registers for asm_switch_context() */
        for (i = 0; i < CPU_SAVED_REGS_CNT; i++)