[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20171023135819.g5yo3x65vkekshvk@naverao1-tp.localdomain>
Date: Mon, 23 Oct 2017 19:28:19 +0530
From: "Naveen N. Rao" <naveen.n.rao@...ux.vnet.ibm.com>
To: Masami Hiramatsu <mhiramat@...nel.org>
Cc: Ingo Molnar <mingo@...nel.org>,
Michael Ellerman <mpe@...erman.id.au>,
Ananth N Mavinakayanahalli <ananth@...ux.vnet.ibm.com>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Revert "kprobes: Warn if optprobe handler tries to
change execution path"
On 2017/10/19 09:38PM, Masami Hiramatsu wrote:
> On Tue, 17 Oct 2017 13:48:34 +0530
> "Naveen N. Rao" <naveen.n.rao@...ux.vnet.ibm.com> wrote:
>
> > This reverts commit e863d539614641 ("kprobes: Warn if optprobe handler
> > tries to change execution path").
> >
> > On powerpc, we place a probe at kretprobe_trampoline to catch function
> > returns and with CONFIG_OPTPROBES, this probe gets optimized. This
> > works for us due to the way we handle the optprobe as described in
> > commit 762df10bad6954 ("powerpc/kprobes: Optimize kprobe
> > in kretprobe_trampoline()"). With the above commit, we end up with a
> > warning. As such, revert this change.
>
> OK, so for ppc, optprobe can handle nip change.
>
> Acked-by: Masami Hiramatsu <mhiramat@...nel.org>
>
> I'll update the document too.
Thanks. We don't quite handle the nip change (yet), but just work around
it for kretprobe trampoline by using the link register, and issuing a
'blr' after the trampoline code.
Regards,
Naveen
Powered by blists - more mailing lists