diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -338,8 +338,9 @@ td->td_md.md_spinlock_count); } #endif - if (td->td_critnest != 0 || WITNESS_CHECK(WARN_SLEEPOK | - WARN_GIANTOK, NULL, "Kernel page fault") != 0) { + if ((td->td_pflags & TDP_NOFAULTING) == 0 && + (td->td_critnest != 0 || WITNESS_CHECK(WARN_SLEEPOK | + WARN_GIANTOK, NULL, "Kernel page fault") != 0)) { print_registers(frame); print_gp_register("far", far); printf(" esr: 0x%.16lx\n", esr);