]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Stack unwinding robustness fixes for RISC-V.
authorjhb <jhb@FreeBSD.org>
Tue, 8 Dec 2020 17:57:18 +0000 (17:57 +0000)
committerjhb <jhb@FreeBSD.org>
Tue, 8 Dec 2020 17:57:18 +0000 (17:57 +0000)
commit8e237bb9e26990753638889526895620c55a8876
treef0a31219b740d97a5350509330dceab40bf8b5f8
parent1889068bc4abb27f68f3b6e50e4ce97f2b364c65
Stack unwinding robustness fixes for RISC-V.

- Push the kstack_contains check down into unwind_frame() so that it
  is honored by DDB and DTrace.

- Check that the trapframe for an exception frame is contained in the
  traced thread's kernel stack for DDB traces.

Reviewed by: markj
Obtained from: CheriBSD
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D27357
sys/cddl/dev/dtrace/riscv/dtrace_isa.c
sys/cddl/dev/fbt/fbt.c
sys/riscv/include/stack.h
sys/riscv/riscv/db_trace.c
sys/riscv/riscv/stack_machdep.c
sys/riscv/riscv/unwind.c