diff options
author | Marcin Nowakowski <marcin.nowakowski@imgtec.com> | 2016-09-22 15:38:31 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-10-07 15:21:20 +0200 |
commit | 8e60b04467ba451e941d0f7c8c0885467911e82d (patch) | |
tree | 8b16b45970e11a1493c29f4271114cef5ee5d189 | |
parent | 65057b0f12254a2e821999d7cda9013c093aa931 (diff) | |
download | lwn-8e60b04467ba451e941d0f7c8c0885467911e82d.tar.gz lwn-8e60b04467ba451e941d0f7c8c0885467911e82d.zip |
MIPS: fix uretprobe implementation
commit db06068a4fd44a57b642b369d2a295b8448f6b65 upstream.
arch_uretprobe_hijack_return_addr should replace the return address for
a call with a trampoline address.
Signed-off-by: Marcin Nowakowski <marcin.nowakowski@imgtec.com>
Fixes: 40e084a506eb ('MIPS: Add uprobes support.')
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/14298/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | arch/mips/kernel/uprobes.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/mips/kernel/uprobes.c b/arch/mips/kernel/uprobes.c index 33bc03e264ab..c01ff4a95dc4 100644 --- a/arch/mips/kernel/uprobes.c +++ b/arch/mips/kernel/uprobes.c @@ -257,7 +257,7 @@ unsigned long arch_uretprobe_hijack_return_addr( ra = regs->regs[31]; /* Replace the return address with the trampoline address */ - regs->regs[31] = ra; + regs->regs[31] = trampoline_vaddr; return ra; } |