Changeset eb522e8 in mainline for kernel/arch/ia32/include/context_offset.h
- Timestamp:
- 2011-06-01T08:43:42Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 8d6c1f1
- Parents:
- 9e2e715 (diff), e51a514 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/ia32/include/context_offset.h
r9e2e715 reb522e8 27 27 */ 28 28 29 /** @addtogroup ia32 29 /** @addtogroup ia32 30 30 * @{ 31 31 */ … … 36 36 #define KERN_ia32_CONTEXT_OFFSET_H_ 37 37 38 #define OFFSET_SP 0x039 #define OFFSET_PC 0x440 #define OFFSET_EBX 0x841 #define OFFSET_ESI 0xC42 #define OFFSET_EDI 0x1043 #define OFFSET_EBP 0x1438 #define OFFSET_SP 0x00 39 #define OFFSET_PC 0x04 40 #define OFFSET_EBX 0x08 41 #define OFFSET_ESI 0x0C 42 #define OFFSET_EDI 0x10 43 #define OFFSET_EBP 0x14 44 44 45 #ifdef KERNEL 46 # define OFFSET_IPL0x1845 #ifdef KERNEL 46 #define OFFSET_IPL 0x18 47 47 #else 48 # define OFFSET_TLS0x1848 #define OFFSET_TLS 0x18 49 49 #endif 50 50 51 #ifdef __ASM__ 51 52 52 #ifdef __ASM__ 53 54 # ctx: address of the structure with saved context 53 # ctx: address of the structure with saved context 55 54 # pc: return address 56 55 57 56 .macro CONTEXT_SAVE_ARCH_CORE ctx:req pc:req 58 movl %esp,OFFSET_SP(\ctx) # %esp -> ctx->sp 57 movl %esp,OFFSET_SP(\ctx) # %esp -> ctx->sp 59 58 movl \pc,OFFSET_PC(\ctx) # %eip -> ctx->pc 60 movl %ebx,OFFSET_EBX(\ctx) # %ebx -> ctx->ebx 61 movl %esi,OFFSET_ESI(\ctx) # %esi -> ctx->esi 62 movl %edi,OFFSET_EDI(\ctx) # %edi -> ctx->edi 63 movl %ebp,OFFSET_EBP(\ctx) # %ebp -> ctx->ebp 59 movl %ebx,OFFSET_EBX(\ctx) # %ebx -> ctx->ebx 60 movl %esi,OFFSET_ESI(\ctx) # %esi -> ctx->esi 61 movl %edi,OFFSET_EDI(\ctx) # %edi -> ctx->edi 62 movl %ebp,OFFSET_EBP(\ctx) # %ebp -> ctx->ebp 64 63 .endm 65 64 66 # ctx: address of the structure with saved context 65 # ctx: address of the structure with saved context 67 66 68 67 .macro CONTEXT_RESTORE_ARCH_CORE ctx:req pc:req … … 75 74 .endm 76 75 77 #endif /* __ASM__ */ 76 #endif /* __ASM__ */ 78 77 79 78 #endif … … 81 80 /** @} 82 81 */ 83
Note:
See TracChangeset
for help on using the changeset viewer.