Changeset 85207 in vbox for trunk/include
- Timestamp:
- Jul 10, 2020 9:31:49 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/time.h
r85206 r85207 356 356 } 357 357 358 /** @def RTTIME_LINUX_KERNEL_PREREQ 359 * @note Cannot really be moved to iprt/cdefs.h, see the-linux-kernel.h */ 360 #if defined(RT_OS_LINUX) && defined(LINUX_KERNEL_VERSION) && defined(KERNEL_VERSION) 361 # define RTTIME_LINUX_KERNEL_PREREQ(a, b, c) (LINUX_VERSION_CODE < KERNEL_VERSION(a,b,c)) 362 #else 363 # define RTTIME_LINUX_KERNEL_PREREQ(a, b, c) 0 364 #endif 358 365 359 366 /* PORTME: Add struct timeval guard macro here. */ … … 365 372 || ( defined(RT_OS_LINUX) \ 366 373 && defined(_LINUX_TIME_H) \ 367 && (!defined(__KERNEL__) /* || < 5.6-rc3 - but we don't need this in ring-0. @bugref{9757} */)) \374 && (!defined(__KERNEL__) || !RTTIME_LINUX_KERNEL_PREREQ(5,6,0)) /* @bugref{9757} */ ) \ 368 375 || (defined(RT_OS_NETBSD) && defined(_SYS_TIME_H_)) 369 376 … … 411 418 || defined(_TIMESPEC) \ 412 419 || ( defined(_STRUCT_TIMESPEC) \ 413 && (!defined(RT_OS_LINUX) || !defined(__KERNEL__) /* || < 5.6-rc3 - but we don't need this in ring-0. @bugref{9757} */) ) \ 420 && ( !defined(RT_OS_LINUX) \ 421 || !defined(__KERNEL__) \ 422 || !RTTIME_LINUX_KERNEL_PREREQ(5,6,0) /* @bugref{9757} */)) \ 414 423 || (defined(RT_OS_NETBSD) && defined(_SYS_TIME_H_)) 415 424 … … 459 468 * @param pTimespec Where to store the time as linux 64-bit timespec. 460 469 */ 461 DECLINLINE(struct timespec64 *) RTTimeSpec SetTimespec64(PCRTTIMESPEC pTime, struct timespec64 *pTimespec)470 DECLINLINE(struct timespec64 *) RTTimeSpecGetTimespec64(PCRTTIMESPEC pTime, struct timespec64 *pTimespec) 462 471 { 463 472 int64_t i64 = RTTimeSpecGetNano(pTime);
Note:
See TracChangeset
for help on using the changeset viewer.