Prevents an infinite pagefault/pmap_enter() loop when ktracing apps
doing a lot of futex(2) calls like firefox & chrome.
-/* $OpenBSD: sys_futex.c,v 1.5 2017/12/19 16:41:43 deraadt Exp $ */
+/* $OpenBSD: sys_futex.c,v 1.6 2018/01/08 22:33:13 mpi Exp $ */
/*
* Copyright (c) 2016-2017 Martin Pieuchot
return error;
#ifdef KTRACE
if (KTRPOINT(p, KTR_STRUCT))
- ktrabstimespec(p, timeout);
+ ktrabstimespec(p, &ts);
#endif
to_ticks = (uint64_t)hz * ts.tv_sec +
(ts.tv_nsec + tick * 1000 - 1) / (tick * 1000) + 1;