提交 a5312f56 编写于 作者: X Xunlei Pang 提交者: Ingo Molnar

alpha, rtc: Change to use rtc_class_ops's set_mmss64()

Change alpha_rtc_set_mmss() and remote_set_mmss() to use
rtc_class_ops's set_mmss64(), to be y2038 safe.
Signed-off-by: NXunlei Pang <pang.xunlei@linaro.org>
Signed-off-by: NJohn Stultz <john.stultz@linaro.org>
Acked-by: NAlessandro Zummo <a.zummo@towertech.it>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Richard Henderson <rth@twiddle.net>
Link: http://lkml.kernel.org/r/1427945681-29972-15-git-send-email-john.stultz@linaro.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
上级 933623c3
...@@ -116,7 +116,7 @@ alpha_rtc_set_time(struct device *dev, struct rtc_time *tm) ...@@ -116,7 +116,7 @@ alpha_rtc_set_time(struct device *dev, struct rtc_time *tm)
} }
static int static int
alpha_rtc_set_mmss(struct device *dev, unsigned long nowtime) alpha_rtc_set_mmss(struct device *dev, time64_t nowtime)
{ {
int retval = 0; int retval = 0;
int real_seconds, real_minutes, cmos_minutes; int real_seconds, real_minutes, cmos_minutes;
...@@ -211,7 +211,7 @@ alpha_rtc_ioctl(struct device *dev, unsigned int cmd, unsigned long arg) ...@@ -211,7 +211,7 @@ alpha_rtc_ioctl(struct device *dev, unsigned int cmd, unsigned long arg)
static const struct rtc_class_ops alpha_rtc_ops = { static const struct rtc_class_ops alpha_rtc_ops = {
.read_time = alpha_rtc_read_time, .read_time = alpha_rtc_read_time,
.set_time = alpha_rtc_set_time, .set_time = alpha_rtc_set_time,
.set_mmss = alpha_rtc_set_mmss, .set_mmss64 = alpha_rtc_set_mmss,
.ioctl = alpha_rtc_ioctl, .ioctl = alpha_rtc_ioctl,
}; };
...@@ -276,7 +276,7 @@ do_remote_mmss(void *data) ...@@ -276,7 +276,7 @@ do_remote_mmss(void *data)
} }
static int static int
remote_set_mmss(struct device *dev, unsigned long now) remote_set_mmss(struct device *dev, time64_t now)
{ {
union remote_data x; union remote_data x;
if (smp_processor_id() != boot_cpuid) { if (smp_processor_id() != boot_cpuid) {
...@@ -290,7 +290,7 @@ remote_set_mmss(struct device *dev, unsigned long now) ...@@ -290,7 +290,7 @@ remote_set_mmss(struct device *dev, unsigned long now)
static const struct rtc_class_ops remote_rtc_ops = { static const struct rtc_class_ops remote_rtc_ops = {
.read_time = remote_read_time, .read_time = remote_read_time,
.set_time = remote_set_time, .set_time = remote_set_time,
.set_mmss = remote_set_mmss, .set_mmss64 = remote_set_mmss,
.ioctl = alpha_rtc_ioctl, .ioctl = alpha_rtc_ioctl,
}; };
#endif #endif
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册