|
@@ -197,3 +197,21 @@ void reset_cpu (unsigned long ignored)
|
|
/*enable functional WDT clock */
|
|
/*enable functional WDT clock */
|
|
writel(APBC_APBCLK | APBC_FNCLK, &mpmu->wdtpcr);
|
|
writel(APBC_APBCLK | APBC_FNCLK, &mpmu->wdtpcr);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+/*
|
|
|
|
+ * This function is derived from PowerPC code (read timebase as long long).
|
|
|
|
+ * On ARM it just returns the timer value.
|
|
|
|
+ */
|
|
|
|
+unsigned long long get_ticks(void)
|
|
|
|
+{
|
|
|
|
+ return get_timer(0);
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+/*
|
|
|
|
+ * This function is derived from PowerPC code (timebase clock frequency).
|
|
|
|
+ * On ARM it returns the number of timer ticks per second.
|
|
|
|
+ */
|
|
|
|
+ulong get_tbclk (void)
|
|
|
|
+{
|
|
|
|
+ return (ulong)CONFIG_SYS_HZ;
|
|
|
|
+}
|