From: David S. Miller Date: Fri, 3 Mar 2006 04:28:34 +0000 (-0800) Subject: [SPARC64]: Fix mini RTC driver reading. X-Git-Tag: v2.6.17-rc1~1184^2~26 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c4f8ef77f941e7d89a52fad1fbe04d59397e2bd1;p=linux-2.6 [SPARC64]: Fix mini RTC driver reading. Need to subtract 1900 from year and 1 from month before giving it back to userspace. Signed-off-by: David S. Miller --- diff --git a/arch/sparc64/kernel/time.c b/arch/sparc64/kernel/time.c index d50ebeae14..7d61f1bfd3 100644 --- a/arch/sparc64/kernel/time.c +++ b/arch/sparc64/kernel/time.c @@ -1363,6 +1363,8 @@ static inline void mini_get_rtc_time(struct rtc_time *time) spin_unlock_irqrestore(&rtc_lock, flags); to_tm(seconds, time); + time->tm_year -= 1900; + time->tm_mon -= 1; } static inline int mini_set_rtc_time(struct rtc_time *time)