Skip to content
Commit 3b84efc0 authored by Masami Hiramatsu (Google)'s avatar Masami Hiramatsu (Google) Committed by Will Deacon
Browse files

arm64: kprobes: Return DBG_HOOK_ERROR if kprobes can not handle a BRK



Return DBG_HOOK_ERROR if kprobes can not handle a BRK because it
fails to find a kprobe corresponding to the address.

Since arm64 kprobes uses stop_machine based text patching for removing
BRK, it ensures all running kprobe_break_handler() is done at that point.
And after removing the BRK, it removes the kprobe from its hash list.
Thus, if the kprobe_break_handler() fails to find kprobe from hash list,
there is a bug.

Signed-off-by: default avatarMasami Hiramatsu (Google) <mhiramat@kernel.org>
Acked-by: default avatarMark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/166994753273.439920.6629626290560350760.stgit@devnote3


Signed-off-by: default avatarWill Deacon <will@kernel.org>
parent 30a42155
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment