diff options
| author | Ryan Libby <rlibby@FreeBSD.org> | 2026-05-08 19:37:24 +0000 |
|---|---|---|
| committer | Ryan Libby <rlibby@FreeBSD.org> | 2026-05-08 19:37:24 +0000 |
| commit | 324d53c26b2399d9b44fdd08e9c5af650f4ec3ae (patch) | |
| tree | aa5a8bf78845a5e19caae41c83f66f4f4acb7c26 | |
| parent | 94323513dd5070bf1fc3c191c560bd7e17da8931 (diff) | |
sys/time: rework saturation ifdef to avoid direct arch ref
Suggested by: kib
Reviewed by: imp, kib
Differential Revision: https://reviews.freebsd.org/D56401
| -rw-r--r-- | sys/sys/time.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/sys/time.h b/sys/sys/time.h index 6f18d8bd844d..5255d3bc9c7e 100644 --- a/sys/sys/time.h +++ b/sys/sys/time.h @@ -355,7 +355,7 @@ tstosbt(struct timespec _ts) static __inline sbintime_t tstosbt_sat(struct timespec _ts) { -#ifndef __i386__ +#if __SIZEOF_TIME_T > 4 if (_ts.tv_sec > SBT_MAX >> 32) return (SBT_MAX); if (_ts.tv_sec < -(SBT_MAX >> 32) - 1) @@ -384,7 +384,7 @@ tvtosbt(struct timeval _tv) static __inline sbintime_t tvtosbt_sat(struct timeval _tv) { -#ifndef __i386__ +#if __SIZEOF_TIME_T > 4 if (_tv.tv_sec > SBT_MAX >> 32) return (SBT_MAX); if (_tv.tv_sec < -(SBT_MAX >> 32) - 1) |
