X-Git-Url: http://pilppa.org/gitweb/?a=blobdiff_plain;f=arch%2Farm%2Fkernel%2Fptrace.c;h=df653ea59250a3152a5e16f4634d10e93251a9dd;hb=693ac389326a87d608baa2902c45a6e78ed46681;hp=5feee722ea9878e08a9f6415fe7de8e45d7595f9;hpb=347c53dca73fca317d57781f510f5ff4f6c0d0d7;p=linux-2.6-omap-h63xx.git diff --git a/arch/arm/kernel/ptrace.c b/arch/arm/kernel/ptrace.c index 5feee722ea9..df653ea5925 100644 --- a/arch/arm/kernel/ptrace.c +++ b/arch/arm/kernel/ptrace.c @@ -18,8 +18,8 @@ #include #include #include +#include -#include #include #include #include @@ -126,7 +126,7 @@ ptrace_getrn(struct task_struct *child, unsigned long insn) val = get_user_reg(child, reg); if (reg == 15) - val = pc_pointer(val + 8); + val += 8; return val; } @@ -278,8 +278,7 @@ get_branch_address(struct task_struct *child, unsigned long pc, unsigned long in else base -= aluop2; } - if (read_u32(child, base, &alt) == 0) - alt = pc_pointer(alt); + read_u32(child, base, &alt); } break; @@ -305,8 +304,7 @@ get_branch_address(struct task_struct *child, unsigned long pc, unsigned long in base = ptrace_getrn(child, insn); - if (read_u32(child, base + nr_regs, &alt) == 0) - alt = pc_pointer(alt); + read_u32(child, base + nr_regs, &alt); break; } break; @@ -382,16 +380,16 @@ static void clear_breakpoint(struct task_struct *task, struct debug_entry *bp) if (ret != 2 || old_insn.thumb != BREAKINST_THUMB) printk(KERN_ERR "%s:%d: corrupted Thumb breakpoint at " - "0x%08lx (0x%04x)\n", task->comm, task->pid, - addr, old_insn.thumb); + "0x%08lx (0x%04x)\n", task->comm, + task_pid_nr(task), addr, old_insn.thumb); } else { ret = swap_insn(task, addr & ~3, &old_insn.arm, &bp->insn.arm, 4); if (ret != 4 || old_insn.arm != BREAKINST_ARM) printk(KERN_ERR "%s:%d: corrupted ARM breakpoint at " - "0x%08lx (0x%08x)\n", task->comm, task->pid, - addr, old_insn.arm); + "0x%08lx (0x%08x)\n", task->comm, + task_pid_nr(task), addr, old_insn.arm); } }