git: 9cab59fe05b4 - stable/13 - Handle the arm64 unknown exception separately
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 25 Sep 2023 11:00:46 UTC
The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=9cab59fe05b492b23e10ff9c507511cdaa97bae4 commit 9cab59fe05b492b23e10ff9c507511cdaa97bae4 Author: Andrew Turner <andrew@FreeBSD.org> AuthorDate: 2023-03-31 09:15:45 +0000 Commit: Andrew Turner <andrew@FreeBSD.org> CommitDate: 2023-09-25 08:41:15 +0000 Handle the arm64 unknown exception separately Rather than falling through to the default case handle the unknown exception with its own panic message. As ESR_EL1 is zero for this exception stop printing it. Sponsored by: Arm Ltd (cherry picked from commit 3a0cc6fe61ea29334c17dfb71bf24ba9e604ab4c) --- sys/arm64/arm64/trap.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c index bc2136cb9e80..10a2138d9625 100644 --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -513,9 +513,12 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) case EXCP_UNKNOWN: if (undef_insn(1, frame)) break; - printf("Undefined instruction: %08x\n", + far = READ_SPECIALREG(far_el1); + print_registers(frame); + print_gp_register("far", far); + panic("Undefined instruction: %08x", *(uint32_t *)frame->tf_elr); - /* FALLTHROUGH */ + break; default: print_registers(frame); print_gp_register("far", READ_SPECIALREG(far_el1));