diff options
author | Paul Mackerras <paulus@samba.org> | 2005-10-28 08:45:25 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-10-28 08:45:25 -0400 |
commit | d73e0c99f5c45e7b86d38725a4ff49f6746f5353 (patch) | |
tree | 92bc8a15a55ece53c6860af5c2d9ec6ce4d006a8 /arch/powerpc/kernel | |
parent | 007e8f51b26ae7b6a17651af5a0f01ab6491cdca (diff) |
powerpc: Rename asm offset TRAP to _TRAP for 32-bit
... for consistency with 64-bit.
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r-- | arch/powerpc/kernel/asm-offsets.c | 3 | ||||
-rw-r--r-- | arch/powerpc/kernel/entry_32.S | 44 | ||||
-rw-r--r-- | arch/powerpc/kernel/head_32.S | 2 | ||||
-rw-r--r-- | arch/powerpc/kernel/head_4xx.S | 2 | ||||
-rw-r--r-- | arch/powerpc/kernel/head_8xx.S | 2 |
5 files changed, 26 insertions, 27 deletions
diff --git a/arch/powerpc/kernel/asm-offsets.c b/arch/powerpc/kernel/asm-offsets.c index 710336a9f0fd..330cd783206f 100644 --- a/arch/powerpc/kernel/asm-offsets.c +++ b/arch/powerpc/kernel/asm-offsets.c | |||
@@ -209,6 +209,7 @@ int main(void) | |||
209 | DEFINE(_DSISR, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, dsisr)); | 209 | DEFINE(_DSISR, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, dsisr)); |
210 | DEFINE(ORIG_GPR3, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, orig_gpr3)); | 210 | DEFINE(ORIG_GPR3, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, orig_gpr3)); |
211 | DEFINE(RESULT, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, result)); | 211 | DEFINE(RESULT, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, result)); |
212 | DEFINE(_TRAP, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, trap)); | ||
212 | #ifndef CONFIG_PPC64 | 213 | #ifndef CONFIG_PPC64 |
213 | DEFINE(_MQ, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, mq)); | 214 | DEFINE(_MQ, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, mq)); |
214 | /* | 215 | /* |
@@ -219,9 +220,7 @@ int main(void) | |||
219 | */ | 220 | */ |
220 | DEFINE(_DEAR, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, dar)); | 221 | DEFINE(_DEAR, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, dar)); |
221 | DEFINE(_ESR, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, dsisr)); | 222 | DEFINE(_ESR, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, dsisr)); |
222 | DEFINE(TRAP, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, trap)); | ||
223 | #else /* CONFIG_PPC64 */ | 223 | #else /* CONFIG_PPC64 */ |
224 | DEFINE(_TRAP, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, trap)); | ||
225 | DEFINE(SOFTE, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, softe)); | 224 | DEFINE(SOFTE, STACK_FRAME_OVERHEAD+offsetof(struct pt_regs, softe)); |
226 | 225 | ||
227 | /* These _only_ to be used with {PROM,RTAS}_FRAME_SIZE!!! */ | 226 | /* These _only_ to be used with {PROM,RTAS}_FRAME_SIZE!!! */ |
diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S index 960da7bea043..2e99ae41723c 100644 --- a/arch/powerpc/kernel/entry_32.S +++ b/arch/powerpc/kernel/entry_32.S | |||
@@ -278,7 +278,7 @@ ret_from_fork: | |||
278 | syscall_dotrace: | 278 | syscall_dotrace: |
279 | SAVE_NVGPRS(r1) | 279 | SAVE_NVGPRS(r1) |
280 | li r0,0xc00 | 280 | li r0,0xc00 |
281 | stw r0,TRAP(r1) | 281 | stw r0,_TRAP(r1) |
282 | addi r3,r1,STACK_FRAME_OVERHEAD | 282 | addi r3,r1,STACK_FRAME_OVERHEAD |
283 | bl do_syscall_trace_enter | 283 | bl do_syscall_trace_enter |
284 | lwz r0,GPR0(r1) /* Restore original registers */ | 284 | lwz r0,GPR0(r1) /* Restore original registers */ |
@@ -299,12 +299,12 @@ syscall_exit_work: | |||
299 | ori r10,r10,MSR_EE | 299 | ori r10,r10,MSR_EE |
300 | SYNC | 300 | SYNC |
301 | MTMSRD(r10) /* re-enable interrupts */ | 301 | MTMSRD(r10) /* re-enable interrupts */ |
302 | lwz r4,TRAP(r1) | 302 | lwz r4,_TRAP(r1) |
303 | andi. r4,r4,1 | 303 | andi. r4,r4,1 |
304 | beq 4f | 304 | beq 4f |
305 | SAVE_NVGPRS(r1) | 305 | SAVE_NVGPRS(r1) |
306 | li r4,0xc00 | 306 | li r4,0xc00 |
307 | stw r4,TRAP(r1) | 307 | stw r4,_TRAP(r1) |
308 | 4: | 308 | 4: |
309 | addi r3,r1,STACK_FRAME_OVERHEAD | 309 | addi r3,r1,STACK_FRAME_OVERHEAD |
310 | bl do_syscall_trace_leave | 310 | bl do_syscall_trace_leave |
@@ -410,49 +410,49 @@ show_syscalls_task: | |||
410 | .globl ppc_sigsuspend | 410 | .globl ppc_sigsuspend |
411 | ppc_sigsuspend: | 411 | ppc_sigsuspend: |
412 | SAVE_NVGPRS(r1) | 412 | SAVE_NVGPRS(r1) |
413 | lwz r0,TRAP(r1) | 413 | lwz r0,_TRAP(r1) |
414 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ | 414 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ |
415 | stw r0,TRAP(r1) /* register set saved */ | 415 | stw r0,_TRAP(r1) /* register set saved */ |
416 | b sys_sigsuspend | 416 | b sys_sigsuspend |
417 | 417 | ||
418 | .globl ppc_rt_sigsuspend | 418 | .globl ppc_rt_sigsuspend |
419 | ppc_rt_sigsuspend: | 419 | ppc_rt_sigsuspend: |
420 | SAVE_NVGPRS(r1) | 420 | SAVE_NVGPRS(r1) |
421 | lwz r0,TRAP(r1) | 421 | lwz r0,_TRAP(r1) |
422 | rlwinm r0,r0,0,0,30 | 422 | rlwinm r0,r0,0,0,30 |
423 | stw r0,TRAP(r1) | 423 | stw r0,_TRAP(r1) |
424 | b sys_rt_sigsuspend | 424 | b sys_rt_sigsuspend |
425 | 425 | ||
426 | .globl ppc_fork | 426 | .globl ppc_fork |
427 | ppc_fork: | 427 | ppc_fork: |
428 | SAVE_NVGPRS(r1) | 428 | SAVE_NVGPRS(r1) |
429 | lwz r0,TRAP(r1) | 429 | lwz r0,_TRAP(r1) |
430 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ | 430 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ |
431 | stw r0,TRAP(r1) /* register set saved */ | 431 | stw r0,_TRAP(r1) /* register set saved */ |
432 | b sys_fork | 432 | b sys_fork |
433 | 433 | ||
434 | .globl ppc_vfork | 434 | .globl ppc_vfork |
435 | ppc_vfork: | 435 | ppc_vfork: |
436 | SAVE_NVGPRS(r1) | 436 | SAVE_NVGPRS(r1) |
437 | lwz r0,TRAP(r1) | 437 | lwz r0,_TRAP(r1) |
438 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ | 438 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ |
439 | stw r0,TRAP(r1) /* register set saved */ | 439 | stw r0,_TRAP(r1) /* register set saved */ |
440 | b sys_vfork | 440 | b sys_vfork |
441 | 441 | ||
442 | .globl ppc_clone | 442 | .globl ppc_clone |
443 | ppc_clone: | 443 | ppc_clone: |
444 | SAVE_NVGPRS(r1) | 444 | SAVE_NVGPRS(r1) |
445 | lwz r0,TRAP(r1) | 445 | lwz r0,_TRAP(r1) |
446 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ | 446 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ |
447 | stw r0,TRAP(r1) /* register set saved */ | 447 | stw r0,_TRAP(r1) /* register set saved */ |
448 | b sys_clone | 448 | b sys_clone |
449 | 449 | ||
450 | .globl ppc_swapcontext | 450 | .globl ppc_swapcontext |
451 | ppc_swapcontext: | 451 | ppc_swapcontext: |
452 | SAVE_NVGPRS(r1) | 452 | SAVE_NVGPRS(r1) |
453 | lwz r0,TRAP(r1) | 453 | lwz r0,_TRAP(r1) |
454 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ | 454 | rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */ |
455 | stw r0,TRAP(r1) /* register set saved */ | 455 | stw r0,_TRAP(r1) /* register set saved */ |
456 | b sys_swapcontext | 456 | b sys_swapcontext |
457 | 457 | ||
458 | /* | 458 | /* |
@@ -469,9 +469,9 @@ handle_page_fault: | |||
469 | cmpwi r3,0 | 469 | cmpwi r3,0 |
470 | beq+ ret_from_except | 470 | beq+ ret_from_except |
471 | SAVE_NVGPRS(r1) | 471 | SAVE_NVGPRS(r1) |
472 | lwz r0,TRAP(r1) | 472 | lwz r0,_TRAP(r1) |
473 | clrrwi r0,r0,1 | 473 | clrrwi r0,r0,1 |
474 | stw r0,TRAP(r1) | 474 | stw r0,_TRAP(r1) |
475 | mr r5,r3 | 475 | mr r5,r3 |
476 | addi r3,r1,STACK_FRAME_OVERHEAD | 476 | addi r3,r1,STACK_FRAME_OVERHEAD |
477 | lwz r4,_DAR(r1) | 477 | lwz r4,_DAR(r1) |
@@ -617,7 +617,7 @@ BEGIN_FTR_SECTION | |||
617 | b 2b | 617 | b 2b |
618 | END_FTR_SECTION_IFSET(CPU_FTR_601) | 618 | END_FTR_SECTION_IFSET(CPU_FTR_601) |
619 | li r10,-1 | 619 | li r10,-1 |
620 | stw r10,TRAP(r11) | 620 | stw r10,_TRAP(r11) |
621 | addi r3,r1,STACK_FRAME_OVERHEAD | 621 | addi r3,r1,STACK_FRAME_OVERHEAD |
622 | lis r10,MSR_KERNEL@h | 622 | lis r10,MSR_KERNEL@h |
623 | ori r10,r10,MSR_KERNEL@l | 623 | ori r10,r10,MSR_KERNEL@l |
@@ -899,12 +899,12 @@ do_user_signal: /* r10 contains MSR_KERNEL here */ | |||
899 | SYNC | 899 | SYNC |
900 | MTMSRD(r10) /* hard-enable interrupts */ | 900 | MTMSRD(r10) /* hard-enable interrupts */ |
901 | /* save r13-r31 in the exception frame, if not already done */ | 901 | /* save r13-r31 in the exception frame, if not already done */ |
902 | lwz r3,TRAP(r1) | 902 | lwz r3,_TRAP(r1) |
903 | andi. r0,r3,1 | 903 | andi. r0,r3,1 |
904 | beq 2f | 904 | beq 2f |
905 | SAVE_NVGPRS(r1) | 905 | SAVE_NVGPRS(r1) |
906 | rlwinm r3,r3,0,0,30 | 906 | rlwinm r3,r3,0,0,30 |
907 | stw r3,TRAP(r1) | 907 | stw r3,_TRAP(r1) |
908 | 2: li r3,0 | 908 | 2: li r3,0 |
909 | addi r4,r1,STACK_FRAME_OVERHEAD | 909 | addi r4,r1,STACK_FRAME_OVERHEAD |
910 | bl do_signal | 910 | bl do_signal |
@@ -936,12 +936,12 @@ nonrecoverable: | |||
936 | BEGIN_FTR_SECTION | 936 | BEGIN_FTR_SECTION |
937 | blr | 937 | blr |
938 | END_FTR_SECTION_IFSET(CPU_FTR_601) | 938 | END_FTR_SECTION_IFSET(CPU_FTR_601) |
939 | lwz r3,TRAP(r1) | 939 | lwz r3,_TRAP(r1) |
940 | andi. r0,r3,1 | 940 | andi. r0,r3,1 |
941 | beq 4f | 941 | beq 4f |
942 | SAVE_NVGPRS(r1) | 942 | SAVE_NVGPRS(r1) |
943 | rlwinm r3,r3,0,0,30 | 943 | rlwinm r3,r3,0,0,30 |
944 | stw r3,TRAP(r1) | 944 | stw r3,_TRAP(r1) |
945 | 4: addi r3,r1,STACK_FRAME_OVERHEAD | 945 | 4: addi r3,r1,STACK_FRAME_OVERHEAD |
946 | bl nonrecoverable_exception | 946 | bl nonrecoverable_exception |
947 | /* shouldn't return */ | 947 | /* shouldn't return */ |
diff --git a/arch/powerpc/kernel/head_32.S b/arch/powerpc/kernel/head_32.S index f8673f7b2b2d..600ea19d08b5 100644 --- a/arch/powerpc/kernel/head_32.S +++ b/arch/powerpc/kernel/head_32.S | |||
@@ -294,7 +294,7 @@ label: \ | |||
294 | 294 | ||
295 | #define EXC_XFER_TEMPLATE(n, hdlr, trap, copyee, tfer, ret) \ | 295 | #define EXC_XFER_TEMPLATE(n, hdlr, trap, copyee, tfer, ret) \ |
296 | li r10,trap; \ | 296 | li r10,trap; \ |
297 | stw r10,TRAP(r11); \ | 297 | stw r10,_TRAP(r11); \ |
298 | li r10,MSR_KERNEL; \ | 298 | li r10,MSR_KERNEL; \ |
299 | copyee(r10, r9); \ | 299 | copyee(r10, r9); \ |
300 | bl tfer; \ | 300 | bl tfer; \ |
diff --git a/arch/powerpc/kernel/head_4xx.S b/arch/powerpc/kernel/head_4xx.S index 10c261c67021..2590e97f5539 100644 --- a/arch/powerpc/kernel/head_4xx.S +++ b/arch/powerpc/kernel/head_4xx.S | |||
@@ -214,7 +214,7 @@ label: | |||
214 | 214 | ||
215 | #define EXC_XFER_TEMPLATE(hdlr, trap, msr, copyee, tfer, ret) \ | 215 | #define EXC_XFER_TEMPLATE(hdlr, trap, msr, copyee, tfer, ret) \ |
216 | li r10,trap; \ | 216 | li r10,trap; \ |
217 | stw r10,TRAP(r11); \ | 217 | stw r10,_TRAP(r11); \ |
218 | lis r10,msr@h; \ | 218 | lis r10,msr@h; \ |
219 | ori r10,r10,msr@l; \ | 219 | ori r10,r10,msr@l; \ |
220 | copyee(r10, r9); \ | 220 | copyee(r10, r9); \ |
diff --git a/arch/powerpc/kernel/head_8xx.S b/arch/powerpc/kernel/head_8xx.S index de0978742221..bc6d1ac55235 100644 --- a/arch/powerpc/kernel/head_8xx.S +++ b/arch/powerpc/kernel/head_8xx.S | |||
@@ -175,7 +175,7 @@ label: \ | |||
175 | 175 | ||
176 | #define EXC_XFER_TEMPLATE(n, hdlr, trap, copyee, tfer, ret) \ | 176 | #define EXC_XFER_TEMPLATE(n, hdlr, trap, copyee, tfer, ret) \ |
177 | li r10,trap; \ | 177 | li r10,trap; \ |
178 | stw r10,TRAP(r11); \ | 178 | stw r10,_TRAP(r11); \ |
179 | li r10,MSR_KERNEL; \ | 179 | li r10,MSR_KERNEL; \ |
180 | copyee(r10, r9); \ | 180 | copyee(r10, r9); \ |
181 | bl tfer; \ | 181 | bl tfer; \ |