diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2005-06-30 11:42:00 +0200 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2005-10-29 20:31:33 +0200 |
commit | c134a5ecdb8f4aee09feca0d4d395915e752fcb8 (patch) | |
tree | 329cc17a215fa9aedfbfefe70b9dd8f29fcdfe45 /arch/mips/kernel/ptrace.c | |
parent | More .set to keep 32-bit processors happy. (diff) | |
download | linux-c134a5ecdb8f4aee09feca0d4d395915e752fcb8.tar.xz linux-c134a5ecdb8f4aee09feca0d4d395915e752fcb8.zip |
Avoid defining variables in the middle of a block which breaks older
compilers.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/kernel/ptrace.c')
-rw-r--r-- | arch/mips/kernel/ptrace.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/arch/mips/kernel/ptrace.c b/arch/mips/kernel/ptrace.c index 2441e32ce820..74283369a1e3 100644 --- a/arch/mips/kernel/ptrace.c +++ b/arch/mips/kernel/ptrace.c @@ -177,19 +177,22 @@ asmlinkage int sys_ptrace(long request, long pid, long addr, long data) write_c0_status(flags); break; } - case DSP_BASE ... DSP_BASE + 5: + case DSP_BASE ... DSP_BASE + 5: { + dspreg_t *dregs; + if (!cpu_has_dsp) { tmp = 0; ret = -EIO; goto out_tsk; } if (child->thread.dsp.used_dsp) { - dspreg_t *dregs = __get_dsp_regs(child); + dregs = __get_dsp_regs(child); tmp = (unsigned long) (dregs[addr - DSP_BASE]); } else { tmp = -1; /* DSP registers yet used */ } break; + } case DSP_CONTROL: if (!cpu_has_dsp) { tmp = 0; @@ -270,15 +273,18 @@ asmlinkage int sys_ptrace(long request, long pid, long addr, long data) else child->thread.fpu.soft.fcr31 = data; break; - case DSP_BASE ... DSP_BASE + 5: + case DSP_BASE ... DSP_BASE + 5: { + dspreg_t *dregs; + if (!cpu_has_dsp) { ret = -EIO; break; } - dspreg_t *dregs = __get_dsp_regs(child); + dregs = __get_dsp_regs(child); dregs[addr - DSP_BASE] = data; break; + } case DSP_CONTROL: if (!cpu_has_dsp) { ret = -EIO; |