riscv: add do_page_fault and do_trap_break into the kprobes blacklist

These two functions are used to implement the kprobes feature so they
can't be kprobed.

Fixes: c22b0bcb1d ("riscv: Add kprobes supported")
Cc: stable@vger.kernel.org
Signed-off-by: Jisheng Zhang <jszhang@kernel.org>
Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
This commit is contained in:
Jisheng Zhang 2021-03-30 02:12:26 +08:00 committed by Palmer Dabbelt
parent 199fc6b8de
commit 2349a3b26e
No known key found for this signature in database
GPG key ID: 2E1319F35FBB1889
2 changed files with 2 additions and 0 deletions

View file

@ -178,6 +178,7 @@ asmlinkage __visible void do_trap_break(struct pt_regs *regs)
else
die(regs, "Kernel BUG");
}
NOKPROBE_SYMBOL(do_trap_break);
#ifdef CONFIG_GENERIC_BUG
int is_valid_bugaddr(unsigned long pc)

View file

@ -328,3 +328,4 @@ asmlinkage void do_page_fault(struct pt_regs *regs)
}
return;
}
NOKPROBE_SYMBOL(do_page_fault);