Re: [PATCH 1/2] powerpc: ptrace CHECK_FULL_REGS

2007-09-24 Thread Benjamin Herrenschmidt
On Mon, 2007-09-24 at 17:59 -0700, Roland McGrath wrote: > > Yup, I think I ditched most of them.. for some reason I decided it > > couldn't happen, but maybe I'm wrong ? > > Well, it's a BUG_ON. It's supposed to be for something that "can't happen". > That's why it's a sanity check, not a wild

Re: [PATCH 1/2] powerpc: ptrace CHECK_FULL_REGS

2007-09-24 Thread Roland McGrath
> Yup, I think I ditched most of them.. for some reason I decided it > couldn't happen, but maybe I'm wrong ? Well, it's a BUG_ON. It's supposed to be for something that "can't happen". That's why it's a sanity check, not a wild assertion. ;-) The 2/2 patch is an example of a bug that CHECK_FULL

Re: [PATCH 1/2] powerpc: ptrace CHECK_FULL_REGS

2007-09-24 Thread Benjamin Herrenschmidt
On Mon, 2007-09-24 at 16:50 -0700, Roland McGrath wrote: > This restores the CHECK_FULL_REGS sanity check to every place that can > access the nonvolatile GPRs for ptrace. This is already done for > native-bitwidth PTRACE_PEEKUSR, but was omitted for many other cases > (32-bit ptrace, PTRACE_GETR

[PATCH 1/2] powerpc: ptrace CHECK_FULL_REGS

2007-09-24 Thread Roland McGrath
This restores the CHECK_FULL_REGS sanity check to every place that can access the nonvolatile GPRs for ptrace. This is already done for native-bitwidth PTRACE_PEEKUSR, but was omitted for many other cases (32-bit ptrace, PTRACE_GETREGS, etc.); I think there may have been more uniform checks befor