summaryrefslogtreecommitdiff
path: root/arch/arm64/kernel/probes
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2021-05-25 10:25:19 +0300
committerPeter Zijlstra <peterz@infradead.org>2021-06-01 17:00:08 +0300
commitec6aba3d2be1ed75b3f4c894bb64a36d40db1f55 (patch)
tree0fd56814090efcd59ce2f2b29906043853764b23 /arch/arm64/kernel/probes
parent9ce4d216fe8b581e4da4406461a4cfc9acbfa679 (diff)
downloadlinux-ec6aba3d2be1ed75b3f4c894bb64a36d40db1f55.tar.xz
kprobes: Remove kprobe::fault_handler
The reason for kprobe::fault_handler(), as given by their comment: * We come here because instructions in the pre/post * handler caused the page_fault, this could happen * if handler tries to access user space by * copy_from_user(), get_user() etc. Let the * user-specified handler try to fix it first. Is just plain bad. Those other handlers are ran from non-preemptible context and had better use _nofault() functions. Also, there is no upstream usage of this. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Christoph Hellwig <hch@lst.de> Acked-by: Masami Hiramatsu <mhiramat@kernel.org> Link: https://lore.kernel.org/r/20210525073213.561116662@infradead.org
Diffstat (limited to 'arch/arm64/kernel/probes')
-rw-r--r--arch/arm64/kernel/probes/kprobes.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/arch/arm64/kernel/probes/kprobes.c b/arch/arm64/kernel/probes/kprobes.c
index d607c9912025..f6b088e9fa70 100644
--- a/arch/arm64/kernel/probes/kprobes.c
+++ b/arch/arm64/kernel/probes/kprobes.c
@@ -284,16 +284,6 @@ int __kprobes kprobe_fault_handler(struct pt_regs *regs, unsigned int fsr)
kprobes_inc_nmissed_count(cur);
/*
- * We come here because instructions in the pre/post
- * handler caused the page_fault, this could happen
- * if handler tries to access user space by
- * copy_from_user(), get_user() etc. Let the
- * user-specified handler try to fix it first.
- */
- if (cur->fault_handler && cur->fault_handler(cur, regs, fsr))
- return 1;
-
- /*
* In case the user-specified fault handler returned
* zero, try to fix up.
*/