Re: [9fans] another kernel question

2008-08-13 Thread Steve Simon
> TEXT forkret(SB), $0 very cunning... thanks russ, I get it now. -Steve

Re: [9fans] another kernel question

2008-08-12 Thread Russ Cox
> this is fine for most calls, however rfork() explicitly sets up->nerrlab > to zero rather than copying it and memmove()ing up->errlab from the parent > proc to the child: > >/sys/src/9/port/sysproc.c:90 > > Surely this means that rfork will always fail with a "bad errstack [19]: -1 > e

[9fans] another kernel question

2008-08-12 Thread Steve Simon
I have found another piece of code I don't understand in the kernel. syscalls are all fed through a single trap, and the common code which processes them performs a waserror(): /sys/src/9/pc/trap.c:694 A few lines down this function (after the system call has been executed up->nerrlab i