pps_fetch: introduce a helper to handle timeouts
authorDan Cross <cross@gajendra.net>
Sat, 11 May 2024 01:46:33 +0000 (01:46 +0000)
committerMatthew Dillon <dillon@apollo.backplane.com>
Wed, 15 May 2024 18:40:06 +0000 (11:40 -0700)
commit0c4dbac108483594a0c23292c970faa8ab75465e
tree4506c4e30cf3552c36a7bc5e09ae5ae33cfee548
parentbbf175be7c123771a0fdbf33e95027bec8b3e14b
pps_fetch: introduce a helper to handle timeouts

Introduce a helper function that handles providing a timeout so that
we can wait for an event, and call it from the PPS_IOC_FETCH ioctl case.
Modeled after the same code in FreeBSD.

Signed-off-by: Dan Cross <cross@gajendra.net>
sys/kern/kern_clock.c