vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hi all, yet another question from yours truly. I've been trying to figure out how OpenBSD handles stack growth for user processes. Near arch/i386/i386/trap.c:368 case T_SEGNPFLT|T_USER: case T_STKFLT|T_USER: sv.sival_int = frame.tf_eip; KERNEL_PROC_LOCK(p); trapsignal(p, SIGSEGV, vftype, SEGV_MAPERR, sv); KERNEL_PROC_UNLOCK(p); goto out; Ok, so trapsignal() gets called to handle the error. But near sys/kern/kern_sig.c:779 (*p->p_emul->e_sendsig)(ps->ps_sigact[signum], signum, Where is the p_emul->e_sendsig set? What is it set to? I did a recursive grep, but no luck - is it set in an assembly file somewhere disguised as a different offset name or something? Or is this only used when running execs from different OS's? Without any additional detail, I'll make a guess that somewhere, somehow, a uvm_map() gets called which will add new stack mappings to the offending process - is this accurate? if not, can anyone point me to the right place to look? Thanks, -Jason Kim |