Re: [PATCH 0/2] kprobes: Fix kretprobe incorrect stacking order problem
From: Steven Rostedt
Date: Mon Jan 07 2019 - 14:59:23 EST
On Mon, 7 Jan 2019 20:52:09 +0100
Andrea Righi <righi.andrea@xxxxxxxxx> wrote:
> > Ug, kretprobe calls spinlocks in the callback? I wonder if we can
> > remove them.
> > I'm guessing this is a different issue than the one that this patch
> > fixes. This sounds like we are calling kretprobe from kretprobe?
> > -- Steve
> -> trampoline_handler()
> -> kretprobe_hash_lock()
> -> raw_spin_lock_irqsave()
> If we put a kretprobe to raw_spin_lock_irqsave() it looks like
> kretprobe is going to call kretprobe...
Right, but we should be able to add some recursion protection to stop
that. I have similar protection in the ftrace code.