git: fb49012ca448 - stable/12 - tests: kqueue: CLOCK_BOOTTIME is an alias of CLOCK_UPTIME

From: Kyle Evans <kevans_at_FreeBSD.org>
Date: Wed, 06 Oct 2021 14:53:16 UTC
The branch stable/12 has been updated by kevans:

URL: https://cgit.FreeBSD.org/src/commit/?id=fb49012ca448f3c7a9ae38ceaf700b8cd39be836

commit fb49012ca448f3c7a9ae38ceaf700b8cd39be836
Author:     Kyle Evans <kevans@FreeBSD.org>
AuthorDate: 2021-10-06 14:50:32 +0000
Commit:     Kyle Evans <kevans@FreeBSD.org>
CommitDate: 2021-10-06 14:50:32 +0000

    tests: kqueue: CLOCK_BOOTTIME is an alias of CLOCK_UPTIME
    
    Build-test should be done a buildenv from a newer branch. =-( We don't
    have this alias in stable/12, so just provide it locally in a way that
    won't break should 155f15118a77 find its way here.
    
    Reported by:    Jenkins, naddy
    Fixes:  f9765c9c1acb ("kqueue: don't arbitrarily restrict ...")
---
 tests/sys/kqueue/libkqueue/timer.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tests/sys/kqueue/libkqueue/timer.c b/tests/sys/kqueue/libkqueue/timer.c
index 81ab364b796c..9400ef1daa82 100644
--- a/tests/sys/kqueue/libkqueue/timer.c
+++ b/tests/sys/kqueue/libkqueue/timer.c
@@ -26,6 +26,9 @@
 #define	MS_TO_US(t)  ((t) * THOUSAND)	/* Convert milliseconds to microseconds. */
 #define	US_TO_NS(t)  ((t) * THOUSAND)	/* Convert microseconds to nanoseconds. */
 
+#ifndef CLOCK_BOOTTIME
+#define	CLOCK_BOOTTIME	CLOCK_UPTIME
+#endif
 
 /* Get the current time with microsecond precision. Used for
  * sub-second timing to make some timer tests run faster.