On Thu, Oct 17, 2024 at 03:11:35AM -0600, Claudio Jeker wrote: > CVSROOT: /cvs > Module name: src > Changes by: clau...@cvs.openbsd.org 2024/10/17 03:11:35 > > Modified files: > sys/kern : kern_sig.c kern_synch.c > sys/sys : signalvar.h > sys/ufs/mfs : mfs_vfsops.c > > Log message: > Shortcut cursig when called during sleep setup. > > Add deep flag as function argument which is used by the sleep API but > nowhere else. Both calls to sleep_signal_check() should skip the ugly > bits of cursig(). > > In cursig() if deep once it is clear a signal will be taken keep the > signal on the thread siglist and return. sleep_signal_check() will then > return EINTR or ERESTART based on the signal context. There is no reason > to do more in this special case. Especially stop/cont and the ptrace trap > must be skipped here. Once the call makes it to userret the signal will be > picked up again and handled in a safe location. > > Stopping singals need some additional logic since we don't want to abort > the sleep just to stop a process. Since our SIGSTOP handling requires > a major rewrite this will be posponed until then.
regress/lib/libc/sys/t_waitid.c hanged over here and I suspect this is the culprit. ==== run-t_waitid-6 ==== 6 Test that waitid(2) handled stopped/continued process loop ./t_waitid -r 6 /home/src/regress/lib/libc/sys/t_waitid.c:231: 'pid > 0' evaluated to false