Changeset b66cc97 in mainline for kernel/arch/ppc32/src
- Timestamp:
- 2016-04-24T08:00:09Z (9 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 38ad239
- Parents:
- 0407636
- Location:
- kernel/arch/ppc32/src
- Files:
-
- 6 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/ppc32/src/asm.S
r0407636 rb66cc97 27 27 */ 28 28 29 #include <abi/asmtool.h> 29 30 #include <arch/asm/regname.h> 30 31 #include <arch/msr.h> … … 33 34 .text 34 35 35 .global userspace_asm 36 .global iret 37 .global iret_syscall 38 .global memcpy_from_uspace 39 .global memcpy_to_uspace 40 .global memcpy_from_uspace_failover_address 41 .global memcpy_to_uspace_failover_address 42 .global early_putchar 43 44 userspace_asm: 45 36 FUNCTION_BEGIN(userspace_asm) 46 37 /* 47 38 * r3 = uspace_uarg … … 78 69 79 70 rfi 80 81 iret: 82 71 FUNCTION_END(userspace_asm) 72 73 SYMBOL(iret) 83 74 /* Disable interrupts */ 84 75 … … 142 133 rfi 143 134 144 iret_syscall: 145 135 SYMBOL(iret_syscall) 146 136 /* Disable interrupts */ 147 137 … … 204 194 rfi 205 195 206 memcpy_from_uspace: 207 memcpy_to_uspace: 208 196 FUNCTION_BEGIN(memcpy_from_uspace) 197 FUNCTION_BEGIN(memcpy_to_uspace) 209 198 srwi. r7, r5, 3 210 199 addi r6, r3, -4 … … 267 256 mtctr r7 268 257 b 1b 269 270 memcpy_from_uspace_failover_address: 271 memcpy_to_uspace_failover_address: 258 FUNCTION_END(memcpy_from_uspace) 259 FUNCTION_END(memcpy_to_uspace) 260 261 SYMBOL(memcpy_from_uspace_failover_address) 262 SYMBOL(memcpy_to_uspace_failover_address) 272 263 /* Return zero, failure */ 273 264 xor r3, r3, r3 274 265 blr 275 266 276 early_putchar: 267 FUNCTION_BEGIN(early_putchar) 277 268 blr 269 FUNCTION_END(early_putchar) -
kernel/arch/ppc32/src/boot/boot.S
r0407636 rb66cc97 27 27 # 28 28 29 #include <abi/asmtool.h> 29 30 #include <arch/asm/regname.h> 30 31 #include <config.h> … … 32 33 .section K_TEXT_START, "ax" 33 34 34 .global kernel_image_start 35 kernel_image_start: 36 35 SYMBOL(kernel_image_start) 37 36 # load temporal kernel stack 38 37 -
kernel/arch/ppc32/src/context.S
r0407636 rb66cc97 27 27 # 28 28 29 #include <abi/asmtool.h> 29 30 #include <arch/context_struct.h> 30 31 #include <arch/asm/regname.h> … … 32 33 .text 33 34 34 .global context_save_arch 35 .global context_restore_arch 36 37 context_save_arch: 35 FUNCTION_BEGIN(context_save_arch) 38 36 stw sp, CONTEXT_OFFSET_SP(r3) 39 37 stw r2, CONTEXT_OFFSET_R2(r3) … … 67 65 li r3, 1 68 66 blr 67 FUNCTION_END(context_save_arch) 69 68 70 context_restore_arch: 69 FUNCTION_BEGIN(context_restore_arch) 71 70 lwz sp, CONTEXT_OFFSET_SP(r3) 72 71 lwz r2, CONTEXT_OFFSET_R2(r3) … … 100 99 li r3, 0 101 100 blr 101 FUNCTION_END(context_restore_arch) -
kernel/arch/ppc32/src/debug/stacktrace_asm.S
r0407636 rb66cc97 27 27 # 28 28 29 #include <abi/asmtool.h> 29 30 #include <arch/asm/regname.h> 30 31 31 32 .text 32 33 33 .global frame_pointer_get 34 .global program_counter_get 35 36 frame_pointer_get: 34 FUNCTION_BEGIN(frame_pointer_get) 37 35 mr r3, sp 38 36 blr 37 FUNCTION_END(frame_pointer_get) 39 38 40 program_counter_get: 39 FUNCTION_BEGIN(program_counter_get) 41 40 mflr r3 42 41 blr 42 FUNCTION_END(program_counter_get) -
kernel/arch/ppc32/src/dummy.S
r0407636 rb66cc97 27 27 # 28 28 29 #include <abi/asmtool.h> 30 29 31 .text 30 32 31 .global asm_delay_loop 32 .globalsys_tls_set33 .global cpu_halt 33 FUNCTION_BEGIN(sys_tls_set) 34 b sys_tls_set 35 FUNCTION_END(sys_tls_set) 34 36 35 sys_tls_set: 36 b sys_tls_set 37 FUNCTION_BEGIN(asm_delay_loop) 38 blr 39 FUNCTION_END(asm_delay_loop) 37 40 38 asm_delay_loop: 39 blr 40 41 cpu_halt: 41 FUNCTION_BEGIN(cpu_halt) 42 42 b cpu_halt 43 FUNCTION_END(cpu_halt) -
kernel/arch/ppc32/src/exception.S
r0407636 rb66cc97 27 27 # 28 28 29 #include <abi/asmtool.h> 29 30 #include <arch/asm/regname.h> 30 31 #include <arch/msr.h> … … 126 127 127 128 .org 0x100 128 .global exc_system_reset 129 exc_system_reset: 129 SYMBOL(exc_system_reset) 130 130 CONTEXT_STORE 131 131 … … 134 134 135 135 .org 0x200 136 .global exc_machine_check 137 exc_machine_check: 136 SYMBOL(exc_machine_check) 138 137 CONTEXT_STORE 139 138 … … 142 141 143 142 .org 0x300 144 .global exc_data_storage 145 exc_data_storage: 143 SYMBOL(exc_data_storage) 146 144 CONTEXT_STORE 147 145 … … 150 148 151 149 .org 0x400 152 .global exc_instruction_storage 153 exc_instruction_storage: 150 SYMBOL(exc_instruction_storage) 154 151 CONTEXT_STORE 155 152 … … 158 155 159 156 .org 0x500 160 .global exc_external 161 exc_external: 157 SYMBOL(exc_external) 162 158 CONTEXT_STORE 163 159 … … 166 162 167 163 .org 0x600 168 .global exc_alignment 169 exc_alignment: 164 SYMBOL(exc_alignment) 170 165 CONTEXT_STORE 171 166 … … 174 169 175 170 .org 0x700 176 .global exc_program 177 exc_program: 171 SYMBOL(exc_program) 178 172 CONTEXT_STORE 179 173 … … 182 176 183 177 .org 0x800 184 .global exc_fp_unavailable 185 exc_fp_unavailable: 178 SYMBOL(exc_fp_unavailable) 186 179 CONTEXT_STORE 187 180 … … 190 183 191 184 .org 0x900 192 .global exc_decrementer 193 exc_decrementer: 185 SYMBOL(exc_decrementer) 194 186 CONTEXT_STORE 195 187 … … 198 190 199 191 .org 0xa00 200 .global exc_reserved0 201 exc_reserved0: 192 SYMBOL(exc_reserved0) 202 193 CONTEXT_STORE 203 194 … … 206 197 207 198 .org 0xb00 208 .global exc_reserved1 209 exc_reserved1: 199 SYMBOL(exc_reserved1) 210 200 CONTEXT_STORE 211 201 … … 214 204 215 205 .org 0xc00 216 .global exc_syscall 217 exc_syscall: 206 SYMBOL(exc_syscall) 218 207 CONTEXT_STORE 219 208 … … 221 210 222 211 .org 0xd00 223 .global exc_trace 224 exc_trace: 212 SYMBOL(exc_trace) 225 213 CONTEXT_STORE 226 214 … … 229 217 230 218 .org 0x1000 231 .global exc_itlb_miss 232 exc_itlb_miss: 219 SYMBOL(exc_itlb_miss) 233 220 CONTEXT_STORE 234 221 … … 237 224 238 225 .org 0x1100 239 .global exc_dtlb_miss_load 240 exc_dtlb_miss_load: 226 SYMBOL(exc_dtlb_miss_load) 241 227 CONTEXT_STORE 242 228 … … 245 231 246 232 .org 0x1200 247 .global exc_dtlb_miss_store 248 exc_dtlb_miss_store: 233 SYMBOL(exc_dtlb_miss_store) 249 234 CONTEXT_STORE 250 235 -
kernel/arch/ppc32/src/fpu_context.S
r0407636 rb66cc97 27 27 # 28 28 29 #include <abi/asmtool.h> 29 30 #include <arch/asm/regname.h> 30 31 #include <arch/fpu_context_struct.h> … … 32 33 33 34 .text 34 35 .global fpu_context_save36 .global fpu_context_restore37 .global fpu_init38 .global fpu_enable39 .global fpu_disable40 35 41 36 .macro FPU_CONTEXT_STORE r … … 109 104 .endm 110 105 111 fpu_context_save: 106 FUNCTION_BEGIN(fpu_context_save) 112 107 FPU_CONTEXT_STORE r3 113 108 … … 116 111 117 112 blr 113 FUNCTION_END(fpu_context_save) 118 114 119 fpu_context_restore: 115 FUNCTION_BEGIN(fpu_context_restore) 120 116 lfd fr0, FPU_CONTEXT_OFFSET_FPSCR(r3) 121 117 mtfsf 0xff, fr0 … … 124 120 125 121 blr 122 FUNCTION_END(fpu_context_restore) 126 123 127 fpu_init: 124 FUNCTION_BEGIN(fpu_init) 128 125 mfmsr r0 129 126 ori r0, r0, MSR_FP … … 137 134 138 135 blr 136 FUNCTION_END(fpu_init) 139 137 140 fpu_enable: 138 FUNCTION_BEGIN(fpu_enable) 141 139 mfmsr r0 142 140 ori r0, r0, MSR_FP … … 144 142 isync 145 143 blr 144 FUNCTION_END(fpu_enable) 146 145 147 fpu_disable: 146 FUNCTION_BEGIN(fpu_disable) 148 147 mfmsr r0 149 148 li r3, MSR_FP … … 152 151 isync 153 152 blr 153 FUNCTION_END(fpu_disable)
Note:
See TracChangeset
for help on using the changeset viewer.