On Tuesday 29 September 2015 17:17:35 Ksenija Stanojevic wrote:
> struct timespec will overflow in year 2038, so replace it with
> timespec64. And replace functions that use struct timespec,
> timespec_sub with timespec64_sub and getnstimeofday with
> getnstimeofday64. Also use parameters to convert the timespec64 values
> instead of hard code.
> 
> Signed-off-by: Ksenija Stanojevic <[email protected]>

The patch looks correct, and the changelog comment seems ok too.

However, I think it makes sense to do two other changes at the
same time here:

- use ktime_t with ktime_us_delta()/ktime_to_ns to simplify the
  code

- use monotonic time (ktime_get) instead of wall time
  (getnstimeofday64/ktime_get_real) to be more robust against
  leap seconds and settimeofday() calls

        Arnd
_______________________________________________
Y2038 mailing list
[email protected]
https://lists.linaro.org/mailman/listinfo/y2038

Reply via email to