Skip to content

Commit

Permalink
ptrace: cleanup arch_ptrace() on tile
Browse files Browse the repository at this point in the history
Remove checking @addr less than 0 because @addr is now unsigned.

Signed-off-by: Namhyung Kim <namhyung@gmail.com>
Acked-by: Chris Metcalf <cmetcalf@tilera.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Namhyung Kim authored and Linus Torvalds committed Oct 28, 2010
1 parent a9384e2 commit 8c0acac
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arch/tile/kernel/ptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ long arch_ptrace(struct task_struct *child, long request,
switch (request) {

case PTRACE_PEEKUSR: /* Read register from pt_regs. */
if (addr < 0 || addr >= PTREGS_SIZE)
if (addr >= PTREGS_SIZE)
break;
childreg = (char *)task_pt_regs(child) + addr;
#ifdef CONFIG_COMPAT
Expand All @@ -77,7 +77,7 @@ long arch_ptrace(struct task_struct *child, long request,
break;

case PTRACE_POKEUSR: /* Write register in pt_regs. */
if (addr < 0 || addr >= PTREGS_SIZE)
if (addr >= PTREGS_SIZE)
break;
childreg = (char *)task_pt_regs(child) + addr;
#ifdef CONFIG_COMPAT
Expand Down

0 comments on commit 8c0acac

Please sign in to comment.