Changeset 15d0046 in mainline for kernel/arch/ppc32/include/arch/istate.h
- Timestamp:
- 2014-09-12T13:22:33Z (10 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 9b20126
- Parents:
- 8db09e4 (diff), 105d8d6 (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/ppc32/include/arch/istate.h
r8db09e4 r15d0046 40 40 #ifdef KERNEL 41 41 42 #include <arch/istate_struct.h> 42 43 #include <arch/msr.h> 43 44 44 45 #else /* KERNEL */ 45 46 47 #include <libarch/istate_struct.h> 46 48 #include <libarch/msr.h> 47 49 48 50 #endif /* KERNEL */ 49 50 typedef struct istate {51 uint32_t r0;52 uint32_t r2;53 uint32_t r3;54 uint32_t r4;55 uint32_t r5;56 uint32_t r6;57 uint32_t r7;58 uint32_t r8;59 uint32_t r9;60 uint32_t r10;61 uint32_t r11;62 uint32_t r13;63 uint32_t r14;64 uint32_t r15;65 uint32_t r16;66 uint32_t r17;67 uint32_t r18;68 uint32_t r19;69 uint32_t r20;70 uint32_t r21;71 uint32_t r22;72 uint32_t r23;73 uint32_t r24;74 uint32_t r25;75 uint32_t r26;76 uint32_t r27;77 uint32_t r28;78 uint32_t r29;79 uint32_t r30;80 uint32_t r31;81 uint32_t cr;82 uint32_t pc;83 uint32_t msr;84 uint32_t lr;85 uint32_t ctr;86 uint32_t xer;87 uint32_t dar;88 uint32_t r12;89 uint32_t sp;90 } istate_t;91 51 92 52 NO_TRACE static inline void istate_set_retaddr(istate_t *istate, … … 98 58 /** Return true if exception happened while in userspace 99 59 * 60 * The contexts of MSR register was stored in SRR1. 61 * 100 62 */ 101 63 NO_TRACE static inline int istate_from_uspace(istate_t *istate) 102 64 { 103 return (istate-> msr& MSR_PR) != 0;65 return (istate->srr1 & MSR_PR) != 0; 104 66 } 105 67 106 NO_TRACE static inline uintptr_t istate_get_pc(istate_t *istate)68 NO_TRACE static inline sysarg_t istate_get_pc(istate_t *istate) 107 69 { 108 70 return istate->pc; 109 71 } 110 72 111 NO_TRACE static inline uintptr_t istate_get_fp(istate_t *istate)73 NO_TRACE static inline sysarg_t istate_get_fp(istate_t *istate) 112 74 { 113 75 return istate->sp; 114 76 } 77 115 78 116 79 #endif
Note:
See TracChangeset
for help on using the changeset viewer.