[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1445872963-29988-1-git-send-email-chao.deng@linaro.org>
Date: Mon, 26 Oct 2015 23:22:41 +0800
From: DengChao <chao.deng@...aro.org>
To: linux-kernel@...r.kernel.org
Cc: chao.deng@...aro.org
Subject: [PATCH 0/2] ntp:Change the type of time_reftime and replace get_seconds()
The type of ntp static variant "time_reftime" and the type of get_seconds()'s
return value are both unsign long now, which may cause y2038 problem on 32bit systems.
So change time_reftime' type to time64_t, and replace get_seconds with
ktime_get_real_seconds() in ntp.
ktime_get_real_seconds() does the same thing as get_seconds() and is y2038 safe,
but ktime_get_real_seconds holds the timekeeping lock which is also held by the ntp code.
We need timekeeping to provide a none lock version of ktime_get_real_seconds
before we can start to solve the ntp.c's y2038 problem.
The [PATCH 1/2] provides the internal none lock version function.
The [PATCH 2/2] does the real fix.
DengChao (2):
timekeeping: Provide internal function __ktime_get_real_seconds
ntp:Change the type of time_reftime to time64_t and replace
get_seconds with __ktime_get_real_seconds
kernel/time/ntp.c | 10 ++++++----
kernel/time/timekeeping.c | 13 +++++++++++++
kernel/time/timekeeping_internal.h | 2 ++
3 files changed, 21 insertions(+), 4 deletions(-)
--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists