]> Pileus Git - ~andy/linux/blobdiff - arch/sh/kernel/time.c
sh: Set the cfa_offset to 0 if we see a DW_CFA_def_cfa_register op
[~andy/linux] / arch / sh / kernel / time.c
index 2edde32c764be6deb519cdc20b4c8afc82c0ab61..7f95f479060fe9557f78c66252b17b857f4a8605 100644 (file)
@@ -21,6 +21,7 @@
 #include <linux/smp.h>
 #include <linux/rtc.h>
 #include <asm/clock.h>
+#include <asm/hwblk.h>
 #include <asm/rtc.h>
 
 /* Dummy RTC ops */
@@ -91,19 +92,19 @@ module_init(rtc_generic_init);
 
 void (*board_time_init)(void);
 
-unsigned long long sched_clock(void)
-{
-       return (jiffies_64 - INITIAL_JIFFIES) * (NSEC_PER_SEC / HZ);
-}
-
 static void __init sh_late_time_init(void)
 {
        /*
         * Make sure all compiled-in early timers register themselves.
-        * Run probe() for one "earlytimer" device.
+        *
+        * Run probe() for two "earlytimer" devices, these will be the
+        * clockevents and clocksource devices respectively. In the event
+        * that only a clockevents device is available, we -ENODEV on the
+        * clocksource and the jiffies clocksource is used transparently
+        * instead. No error handling is necessary here.
         */
        early_platform_driver_register_all("earlytimer");
-       early_platform_driver_probe("earlytimer", 1, 0);
+       early_platform_driver_probe("earlytimer", 2, 0);
 }
 
 void __init time_init(void)
@@ -111,6 +112,7 @@ void __init time_init(void)
        if (board_time_init)
                board_time_init();
 
+       hwblk_init();
        clk_init();
 
        rtc_sh_get_time(&xtime);