Skip to contentSkip to conversation

s390: monotonic_clock interface.

PATCH In review Heiko Carstens 1 participant 1 message Jan 18, 2006 s390

lore
Share & tools
lore
#0 lore raw

PATCH 3/7 s390: monotonic_clock interface.

From: Jan Glauber <[email protected]>

Add monotonic_clock interface, used by the hangcheck-timer. On s390 this is the same as sched_clock().

---

 arch/s390/kernel/time.c |    9 +++++++++
 1 files changed, 9 insertions(+)
arch/s390/kernel/time.c +9 -0
diff -urpN linux-2.6/arch/s390/kernel/time.c linux-2.6-patched/arch/s390/kernel/time.c
@@ -64,6 +64,15 @@ unsigned long long sched_clock(void)
 	return ((get_clock() - jiffies_timer_cc) * 125) >> 9;
 }
 
+/*
+ * Monotonic_clock - returns # of nanoseconds passed since time_init()
+ */
+unsigned long long monotonic_clock(void)
+{
+	return sched_clock();
+}
+EXPORT_SYMBOL(monotonic_clock);
+
 void tod_to_timeval(__u64 todval, struct timespec *xtime)
 {
 	unsigned long long sec;