MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sleepq_check_timeout

Function sleepq_check_timeout

freebsd/kern/subr_sleepqueue.c:617–631  ·  view source on GitHub ↗

* Check to see if we timed out. */

Source from the content-addressed store, hash-verified

615 * Check to see if we timed out.
616 */
617static inline int
618sleepq_check_timeout(void)
619{
620 struct thread *td;
621 int res;
622
623 res = 0;
624 td = curthread;
625 if (td->td_sleeptimo != 0) {
626 if (td->td_sleeptimo <= sbinuptime())
627 res = EWOULDBLOCK;
628 td->td_sleeptimo = 0;
629 }
630 return (res);
631}
632
633/*
634 * Check to see if we were awoken by a signal.

Callers 2

sleepq_timedwaitFunction · 0.85
sleepq_timedwait_sigFunction · 0.85

Calls 1

sbinuptimeFunction · 0.85

Tested by

no test coverage detected