1 #ifndef _ASM_X86_FRAME_H
2 #define _ASM_X86_FRAME_H
7 * These are stack frame creation macros. They should be used by every
8 * callable non-leaf asm function to make kernel stack traces more reliable.
11 #ifdef CONFIG_FRAME_POINTER
17 _ASM_MOV
%_ASM_SP
, %_ASM_BP
24 #else /* !__ASSEMBLY__ */
27 "push %" _ASM_BP "\n" \
28 _ASM_MOV "%" _ASM_SP ", %" _ASM_BP "\n"
30 #define FRAME_END "pop %" _ASM_BP "\n"
32 #endif /* __ASSEMBLY__ */
34 #define FRAME_OFFSET __ASM_SEL(4, 8)
36 #else /* !CONFIG_FRAME_POINTER */
40 #define FRAME_OFFSET 0
42 #endif /* CONFIG_FRAME_POINTER */
44 #endif /* _ASM_X86_FRAME_H */