Debugging signal 11
Johannes Totz
johannes at jo-t.de
Fri Apr 16 23:51:15 UTC 2021
Hi there,
My init(8) is crashing with a signal 11.
I've added a breakpoint() in kern_sig.c:
static int
issignal(struct thread *td)
{
// [snip]
case (intptr_t)SIG_DFL:
/*
* Don't take default actions on system processes.
*/
if (p->p_pid <= 1) {
#ifdef DIAGNOSTIC
/*
* Are you sure you want to ignore SIGSEGV
* in init? XXX
*/
printf("Process (pid %lu) got signal %d\n",
(u_long)p->p_pid, sig);
breakpoint(); // added by me
#endif
break; /* == ignore */
}
// [snip]
}
That breaks to DDB where I can call dump. So far so good.
But how do I get back to the stack(trace) and instruction that caused
the segv? Either in DDB or KGDB?
Thanks,
Johannes
More information about the freebsd-hackers
mailing list