diff options
author | Michael Neuling <mikey@neuling.org> | 2012-06-25 09:33:23 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2012-07-10 05:18:30 -0400 |
commit | 0b7673c35e9240a364594ac4f2c2dd2c111c0aba (patch) | |
tree | ceb3e3eb6b06a81ace2337fe975ce7fd0b8c4d5e /arch/powerpc/kernel | |
parent | 0972def44fd76899fea8682ec8e3c47d429f33ca (diff) |
powerpc: Enforce usage of R0-R31 where possible
Enforce the use of R0-R31 in macros where possible now we have all the
fixes in.
R0-R31 macros are removed here so that can't be used anymore. They
should not be defined anywhere.
Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r-- | arch/powerpc/kernel/fpu.S | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/arch/powerpc/kernel/fpu.S b/arch/powerpc/kernel/fpu.S index 71c1c73bc65f..e0ada05f2df3 100644 --- a/arch/powerpc/kernel/fpu.S +++ b/arch/powerpc/kernel/fpu.S | |||
@@ -26,7 +26,7 @@ | |||
26 | #include <asm/ptrace.h> | 26 | #include <asm/ptrace.h> |
27 | 27 | ||
28 | #ifdef CONFIG_VSX | 28 | #ifdef CONFIG_VSX |
29 | #define REST_32FPVSRS(n,c,base) \ | 29 | #define __REST_32FPVSRS(n,c,base) \ |
30 | BEGIN_FTR_SECTION \ | 30 | BEGIN_FTR_SECTION \ |
31 | b 2f; \ | 31 | b 2f; \ |
32 | END_FTR_SECTION_IFSET(CPU_FTR_VSX); \ | 32 | END_FTR_SECTION_IFSET(CPU_FTR_VSX); \ |
@@ -35,7 +35,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_VSX); \ | |||
35 | 2: REST_32VSRS(n,c,base); \ | 35 | 2: REST_32VSRS(n,c,base); \ |
36 | 3: | 36 | 3: |
37 | 37 | ||
38 | #define SAVE_32FPVSRS(n,c,base) \ | 38 | #define __SAVE_32FPVSRS(n,c,base) \ |
39 | BEGIN_FTR_SECTION \ | 39 | BEGIN_FTR_SECTION \ |
40 | b 2f; \ | 40 | b 2f; \ |
41 | END_FTR_SECTION_IFSET(CPU_FTR_VSX); \ | 41 | END_FTR_SECTION_IFSET(CPU_FTR_VSX); \ |
@@ -44,9 +44,11 @@ END_FTR_SECTION_IFSET(CPU_FTR_VSX); \ | |||
44 | 2: SAVE_32VSRS(n,c,base); \ | 44 | 2: SAVE_32VSRS(n,c,base); \ |
45 | 3: | 45 | 3: |
46 | #else | 46 | #else |
47 | #define REST_32FPVSRS(n,b,base) REST_32FPRS(n, base) | 47 | #define __REST_32FPVSRS(n,b,base) REST_32FPRS(n, base) |
48 | #define SAVE_32FPVSRS(n,b,base) SAVE_32FPRS(n, base) | 48 | #define __SAVE_32FPVSRS(n,b,base) SAVE_32FPRS(n, base) |
49 | #endif | 49 | #endif |
50 | #define REST_32FPVSRS(n,c,base) __REST_32FPVSRS(n,__REG_##c,__REG_##base) | ||
51 | #define SAVE_32FPVSRS(n,c,base) __SAVE_32FPVSRS(n,__REG_##c,__REG_##base) | ||
50 | 52 | ||
51 | /* | 53 | /* |
52 | * This task wants to use the FPU now. | 54 | * This task wants to use the FPU now. |
@@ -79,7 +81,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_VSX) | |||
79 | beq 1f | 81 | beq 1f |
80 | toreal(r4) | 82 | toreal(r4) |
81 | addi r4,r4,THREAD /* want last_task_used_math->thread */ | 83 | addi r4,r4,THREAD /* want last_task_used_math->thread */ |
82 | SAVE_32FPVSRS(0, r5, r4) | 84 | SAVE_32FPVSRS(0, R5, R4) |
83 | mffs fr0 | 85 | mffs fr0 |
84 | stfd fr0,THREAD_FPSCR(r4) | 86 | stfd fr0,THREAD_FPSCR(r4) |
85 | PPC_LL r5,PT_REGS(r4) | 87 | PPC_LL r5,PT_REGS(r4) |