djprobes status

Ingo Molnar mingo@redhat.com
Sat Sep 16 07:17:00 GMT 2006


On Fri, 2006-09-15 at 20:59 +0200, Ingo Molnar wrote:
> a third possibility would be to generate not a jump straight into the
> trampoline, but a jump to a kprobes-controlled function:
> 
>         pushw $target_IP
>         ret 

ok, that's not enough, in this scheme we'd have to do something like:

	pushl $trampoline_offset
	callq $generic_handler

which is 10 bytes - quite large.

[generic_handler() would then do preempt_disable(), and it would call
the function pointer passed to it and then it would set up a
preempt_enable() call on the stack and jump to the trampoline. When the
trampoline does RET, we'd return to straight after the callq above.]

in that sense the freeze_processes()/thaw_processes() approach sounds
robust, because it would keep the "size of destruction" at the minimal 5
bytes.

	Ingo



More information about the Systemtap mailing list