[lkml]   [2000]   [Sep]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [ANOTHER PATCH] Re: [PATCH] 2.4.0 i386 watchpoint problems

On Fri, 22 Sep 2000, Andi Kleen wrote:
> Also unless I'm missing another thing ptrace allows you to put any addresses
> including kernel address into the debug registers, so you could certainly
> get debug traps everywhere, making my original objection valid.


if(addr < (long) &dummy->u_debugreg[4] &&
((unsigned long) data) >= TASK_SIZE-3) break;

> How does this patch look ?

Horrible. It WILL NOT WORK.

It does a access_ok() that uses the debugger address space to determine if
the debuggee is ok.

Also, debugreg6 is not a linear address at all. Only 0-3 are, so only they
should be tested.

Which is exactly what the test that already exists does.

No, it may not be obvious, but it's all there.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 12:45    [W:0.130 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site