Subject: Re: [patch 06/10] Add notify die hooks and remove some redundant debugger hooks

From: Ananth N Mavinakayanahalli <[email-masked]>
Date: Tue, 10 Apr 2007 10:19:22 +0530

On Mon, Apr 09, 2007 at 08:21:25PM +1000, Paul Mackerras wrote:
> 
> The other thing is that we seem to be throwing all sorts of unrelated
> events into the die_notifier.  The symptom of that is that you have
> one set of handlers that are only interested in the debug events, and
> another set that are only interested in the events where the machine
> really is dying (oops, etc.).  That is, you have two sets of handlers
> that are interested in disjoint sets of events.  That says to me that
> we shouldn't be using a single notifier for all the events.
> Particularly for page faults I really don't see the point of calling
> handlers that are only interested in oopses.

The page fault no longer uses the die_notifier. In recent kernels, we
have done away with registering the page fault notifier unconditionally.
In the kprobe case, its active only if there are any active probes.

As to the debug events vs. dying events both using the die_notifier, we
did it that way just to maintain consistency across platforms. i386,
x86_64 and sparc64 were using similar stuff before we put in the powerpc
portions.

Aside, I was told that some folks use the page fault notifiers to
determine application behaviour or somesuch and have used it effectively
to solve some of their performance issues. I don't have the details
though.

Ananth