| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
Changed kern/timer.c to use the higher precision time_value64_t.
Of course, this won't suffer from the 2038 overflow but it does provide
nanosecond precision (if gnumach ever uses a better timer) and
moves us closer to only having time_value64_t.
Message-Id: <ZA63tGcv3bETUJFJ@jupiter.tail36e24.ts.net>
|
|
|
|
|
| |
We can use these in userland with the new time_value64_t struct.
Message-Id: <Y/RRck2JffqNenif@jupiter.tail36e24.ts.net>
|
|
|
|
|
|
|
| |
5fdc928d3d29 ("fix rpc time value for 64 bit") broke hurd build because
structures are never compatible in C. For userland we however know
that rpc_time_value is the same as time_value, so we can just typedef
rpc_time_value_t to struct time_value as userland is used to.
|
|
|
|
|
|
| |
Also updated the mapped time to support the new 64-bit time while
keeping compatible with the user land programs currently using it so
they can be migrated in parallel.
|
|
|
|
|
|
|
|
|
|
|
|
| |
time_value64_t uses int64_t to track seconds and nanoseconds and hence
is Y2038 proof. It does not have nano second resolution but it could
be provided in the future.
Removed include/sys/time.h as it remaps time_value_t into timeval which
can create confusion.
The timestamp from keyboard and mouse events is no longer set and
replaced with rpc_time_value for better compatibility.
|
|
|
|
|
|
| |
The inline keyword was not defined there, so we need to use __inline__.
This fixes make check in glibc.
|
|
|
|
|
|
|
| |
On 64 bit kernels, seconds will be 64 bits long and won't suffer from
the 2038 problem. We also add a new type rpc_time_value_t to handle the
conversion between 32 bit userland and 64 bit kernel.
Message-Id: <Y50kIaIgaIdGjDAk@mars>
|
|
|
|
|
| |
* include/mach/time_value.h (TIME_VALUE_TO_TIMESPEC,
TIMESPEC_TO_TIME_VALUE): New macros
|
|
|
|
|
|
|
|
| |
* include/mach/time_value.h (struct mapped_time_value): Adjust comment.
* kern/mach_clock.c (mtime): Likewise. Also make it volatile.
(update_mapped_time): Use full hardware barriers.
(read_mapped_time): New macro with proper fences.
(record_time_stamp, host_get_time): Use the new macro.
|
|
|
|
|
|
|
|
|
| |
* include/mach/time_value.h (time_value_assert): New macro to assert
that the given value is well-formed.
(time_value_add_usec): Use the new macro.
(time_value_sub_usec): New macro.
(time_value_add): Use `time_value_add_usec'.
(time_value_sub_usec): New macro.
|
|
|