aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2005-08-05 13:03:06 -0400
committerLen Brown <len.brown@intel.com>2005-08-05 13:03:06 -0400
commite872d4cace8681838e8d18d52c92f4870e980a08 (patch)
tree082b75cc52935efae68f9f744bc3f8807f7176c6 /drivers/char
parent1f3a730117ceda2a7c917d687921fe3c82283968 (diff)
parent403fe5ae57c831968c3dbbaba291ae825a1c5aaa (diff)
Merge ../from-linus
Diffstat (limited to 'drivers/char')
-rw-r--r--drivers/char/rtc.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/char/rtc.c b/drivers/char/rtc.c
index d8f9e94ae475..cd4fe8b1709f 100644
--- a/drivers/char/rtc.c
+++ b/drivers/char/rtc.c
@@ -1209,6 +1209,7 @@ static int rtc_proc_open(struct inode *inode, struct file *file)
1209 1209
1210void rtc_get_rtc_time(struct rtc_time *rtc_tm) 1210void rtc_get_rtc_time(struct rtc_time *rtc_tm)
1211{ 1211{
1212 unsigned long uip_watchdog = jiffies;
1212 unsigned char ctrl; 1213 unsigned char ctrl;
1213#ifdef CONFIG_MACH_DECSTATION 1214#ifdef CONFIG_MACH_DECSTATION
1214 unsigned int real_year; 1215 unsigned int real_year;
@@ -1224,8 +1225,10 @@ void rtc_get_rtc_time(struct rtc_time *rtc_tm)
1224 * Once the read clears, read the RTC time (again via ioctl). Easy. 1225 * Once the read clears, read the RTC time (again via ioctl). Easy.
1225 */ 1226 */
1226 1227
1227 if (rtc_is_updating() != 0) 1228 while (rtc_is_updating() != 0 && jiffies - uip_watchdog < 2*HZ/100) {
1228 msleep(20); 1229 barrier();
1230 cpu_relax();
1231 }
1229 1232
1230 /* 1233 /*
1231 * Only the values that we read from the RTC are set. We leave 1234 * Only the values that we read from the RTC are set. We leave