Skip to content

Commit

Permalink
MIPS: fix uretprobe implementation
Browse files Browse the repository at this point in the history
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: 40e084a ('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>
  • Loading branch information
Marcin Nowakowski authored and Ralf Baechle committed Sep 29, 2016
1 parent 6ca8ac7 commit db06068
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/mips/kernel/uprobes.c
Original file line number Diff line number Diff line change
@@ -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;
}

0 comments on commit db06068

Please sign in to comment.