Changeset d5955a5 in mainline
- Timestamp:
- 2014-09-03T21:58:41Z (10 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 3a07767
- Parents:
- 33add3a8
- Location:
- uspace/lib/c/arch/ppc32
- Files:
-
- 1 added
- 1 deleted
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/arch/ppc32/Makefile.inc
r33add3a8 rd5955a5 37 37 arch/$(UARCH)/src/stacktrace_asm.S 38 38 39 ARCH_AUTOGENS_AG = \ 40 arch/$(UARCH)/include/libarch/fibril_context.ag 41 39 42 .PRECIOUS: arch/$(UARCH)/src/entry.o -
uspace/lib/c/arch/ppc32/include/libarch/fibril.h
r33add3a8 rd5955a5 37 37 38 38 #include <sys/types.h> 39 #include <libarch/fibril_context.h> 39 40 40 41 #define SP_DELTA 16 … … 53 54 } while (0) 54 55 55 typedef struct {56 uint32_t sp;57 uint32_t pc;58 59 uint32_t tls;60 uint32_t r13;61 uint32_t r14;62 uint32_t r15;63 uint32_t r16;64 uint32_t r17;65 uint32_t r18;66 uint32_t r19;67 uint32_t r20;68 uint32_t r21;69 uint32_t r22;70 uint32_t r23;71 uint32_t r24;72 uint32_t r25;73 uint32_t r26;74 uint32_t r27;75 uint32_t r28;76 uint32_t r29;77 uint32_t r30;78 uint32_t r31;79 80 uint32_t cr;81 } __attribute__ ((packed)) context_t;82 83 56 static inline uintptr_t context_get_fp(context_t *ctx) 84 57 { -
uspace/lib/c/arch/ppc32/src/fibril.S
r33add3a8 rd5955a5 33 33 34 34 #include <libarch/regname.h> 35 #include <libarch/ context_offset.h>35 #include <libarch/fibril_context.h> 36 36 37 37 context_save: 38 CONTEXT_SAVE_ARCH_CORE r3 38 stw sp, CONTEXT_OFFSET_SP(r3) 39 stw r2, CONTEXT_OFFSET_TLS(r3) 40 stw r13, CONTEXT_OFFSET_R13(r3) 41 stw r14, CONTEXT_OFFSET_R14(r3) 42 stw r15, CONTEXT_OFFSET_R15(r3) 43 stw r16, CONTEXT_OFFSET_R16(r3) 44 stw r17, CONTEXT_OFFSET_R17(r3) 45 stw r18, CONTEXT_OFFSET_R18(r3) 46 stw r19, CONTEXT_OFFSET_R19(r3) 47 stw r20, CONTEXT_OFFSET_R20(r3) 48 stw r21, CONTEXT_OFFSET_R21(r3) 49 stw r22, CONTEXT_OFFSET_R22(r3) 50 stw r23, CONTEXT_OFFSET_R23(r3) 51 stw r24, CONTEXT_OFFSET_R24(r3) 52 stw r25, CONTEXT_OFFSET_R25(r3) 53 stw r26, CONTEXT_OFFSET_R26(r3) 54 stw r27, CONTEXT_OFFSET_R27(r3) 55 stw r28, CONTEXT_OFFSET_R28(r3) 56 stw r29, CONTEXT_OFFSET_R29(r3) 57 stw r30, CONTEXT_OFFSET_R30(r3) 58 stw r31, CONTEXT_OFFSET_R31(r3) 39 59 40 60 mflr r4 41 stw r4, OFFSET_PC(r3)61 stw r4, CONTEXT_OFFSET_PC(r3) 42 62 43 63 mfcr r4 44 stw r4, OFFSET_CR(r3)64 stw r4, CONTEXT_OFFSET_CR(r3) 45 65 46 66 # context_save returns 1 … … 50 70 51 71 context_restore: 52 CONTEXT_RESTORE_ARCH_CORE r3 72 lwz sp, CONTEXT_OFFSET_SP(r3) 73 lwz r2, CONTEXT_OFFSET_TLS(r3) 74 lwz r13, CONTEXT_OFFSET_R13(r3) 75 lwz r14, CONTEXT_OFFSET_R14(r3) 76 lwz r15, CONTEXT_OFFSET_R15(r3) 77 lwz r16, CONTEXT_OFFSET_R16(r3) 78 lwz r17, CONTEXT_OFFSET_R17(r3) 79 lwz r18, CONTEXT_OFFSET_R18(r3) 80 lwz r19, CONTEXT_OFFSET_R19(r3) 81 lwz r20, CONTEXT_OFFSET_R20(r3) 82 lwz r21, CONTEXT_OFFSET_R21(r3) 83 lwz r22, CONTEXT_OFFSET_R22(r3) 84 lwz r23, CONTEXT_OFFSET_R23(r3) 85 lwz r24, CONTEXT_OFFSET_R24(r3) 86 lwz r25, CONTEXT_OFFSET_R25(r3) 87 lwz r26, CONTEXT_OFFSET_R26(r3) 88 lwz r27, CONTEXT_OFFSET_R27(r3) 89 lwz r28, CONTEXT_OFFSET_R28(r3) 90 lwz r29, CONTEXT_OFFSET_R29(r3) 91 lwz r30, CONTEXT_OFFSET_R30(r3) 92 lwz r31, CONTEXT_OFFSET_R31(r3) 53 93 54 lwz r4, OFFSET_CR(r3)94 lwz r4, CONTEXT_OFFSET_CR(r3) 55 95 mtcr r4 56 96 57 lwz r4, OFFSET_PC(r3)97 lwz r4, CONTEXT_OFFSET_PC(r3) 58 98 mtlr r4 59 99
Note:
See TracChangeset
for help on using the changeset viewer.