Re: [Patch] kprobes exception notifier fix 2.6.9-rc2

From: Prasanna S Panchamukhi
Date: Thu Sep 23 2004 - 03:45:55 EST


Hi Andi,

On Thu, Sep 23, 2004 at 10:06:28AM +0200, Andi Kleen wrote:
> On Thu, Sep 23, 2004 at 11:00:29AM +0530, Prasanna S Panchamukhi wrote:
> > In order to make other debuggers use exception notifiers, kprobes
> > notifier return values are required to be modified. This patch modifies the
> > return values of kprobes notifier return values in a clean way.
>
> It's incompatible to x86-64. If you change anything in exception
> notifiers change both.
>

Yes, I will make the changes to x86_64 exception notifiers as well and
send a patch to you.

> And I don't really see the sense of inverting the test: NOTIFY_OK
> for handling the exception should be as good as NOTIFY_STOP.
>

NOTIFY_OK does not stop notifying others registered for the same event.
This was causing problems when Kprobes and KGDB co-exist and KGDB handler
would get involked, when kprobes handler would have already handled its own
breakpoint. NOTIFY_BAD will also work, but returning NOTIFY_BAD would mean
Bad/Veto action. This patch solves the problem by returning NOTIFY_OK | NOTIFY_STOP_MASK in a clean way.

Please let me know your comments.

Thanks
Prasanna

> -Andi

--
Prasanna S Panchamukhi
Linux Technology Center
India Software Labs, IBM Bangalore
Ph: 91-80-25044636
<prasanna@xxxxxxxxxx>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/