This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fw: kprobe fault handling


richardj_moore wrote:

> [...]  Then kprobes came along and the call-back became an
> entry-point into the probe-handler module. It was supposed to be
> 'longjumped' to if present and the trap stack frame was supposed to
> be discarded by kprobes before the longjump.

Clever.  Is there a supported setjmp/longjmp kernel facility to return
into a kprobes probe handler from within this page fault callback?  We
could use this in systemtap land as a generalization of the current
stable of get_user* routines.  As long as infinite regress is made
impossible, other faults would be just as useful to catch this way.

> [...]  In other words a pagefault would always be silently handled
> and optionally the probe-handler could elect to continue from a
> specified call-back point.  Never was it the intent to allow an
> unhandled pagefault to surface to the kernel, except when
> single-stepping the original instruction. [...]

That sounds well thought out.

- FChE


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]