> Waserror increments up->nerrlab before setting up > the next label on the error stack which means the > poperror in question returns it to zero.
Yep, I get this part, and for nearly all syscalls its straightforward, fork() is different (I was stumpped by that a few months ago), and it seems notes are different too. The difference comes from the fact that sleep is deep inside its stack/errlab hierarchy when it receives a note. This causes it to jump to the notify function (still in the users context), the notify function then calls back into the kernel (noted()). this is where it gets weird, as on entry to the kernel syscall() zeros up->nerrlab and so throws away the processes error history. Then if noted() wants to continue the user process I would expect sleep to get resumed and to recurr out of its stack and hit several poperror()s and end up with a negative nerrlab! so how does it work in the ntoe case? -Steve
