]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: uprobes: fix incorrect uprobe brk handling
authorMarcin Nowakowski <marcin.nowakowski@imgtec.com>
Thu, 11 Aug 2016 07:02:30 +0000 (09:02 +0200)
committerRalf Baechle <ralf@linux-mips.org>
Tue, 13 Sep 2016 12:13:26 +0000 (14:13 +0200)
commit332f9a200b85cd4e964ff9d8ec1020f1a2b0342a
tree326cf2150be2ab513c4bb9321b96c9ee30b2de26
parent117fd3b56aa1f89906c7766ac6e761970a75df31
MIPS: uprobes: fix incorrect uprobe brk handling

When a uprobe-replacement breakpoint instruction is handled, a notifier
is called with DIE_UPROBE argument, but a corresponding exception notify
handler for MIPS attempts to handle DIE_BREAK instead. As a result
the breakpoint instruction isn't handled by the uprobe code and the probed
application terminates with SIGTRAP.
Fix this by changing arch_uprobe_exception_notify code to handle
DIE_UPROBE as a pre-singlestep condition instead of DIE_BREAK.

Signed-off-by: Marcin Nowakowski <marcin.nowakowski@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/13884/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/kernel/uprobes.c