]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/char/rtc.c
smb.h: uses struct timespec but didn't include linux/time.h
[linux-2.6-omap-h63xx.git] / drivers / char / rtc.c
index 5c3142b6f1fcdf102a92b79dec3b9d000b4d4a3b..e2ec2ee4cf79dc4e5f30b1add1d52ecf5f418f77 100644 (file)
@@ -88,6 +88,7 @@
 
 #ifdef CONFIG_SPARC32
 #include <linux/pci.h>
+#include <linux/jiffies.h>
 #include <asm/ebus.h>
 
 static unsigned long rtc_port;
@@ -1316,7 +1317,8 @@ void rtc_get_rtc_time(struct rtc_time *rtc_tm)
         * Once the read clears, read the RTC time (again via ioctl). Easy.
         */
 
-       while (rtc_is_updating() != 0 && jiffies - uip_watchdog < 2*HZ/100)
+       while (rtc_is_updating() != 0 &&
+              time_before(jiffies, uip_watchdog + 2*HZ/100))
                cpu_relax();
 
        /*