time: Correct the *settime* parameters
[profile/ivi/kernel-x86-ivi.git] / kernel / time / timekeeping.c
index c50aaf6..4f9f65b 100644 (file)
@@ -353,7 +353,7 @@ EXPORT_SYMBOL(do_gettimeofday);
  *
  * Sets the time of day to the new time and update NTP and notify hrtimers
  */
-int do_settimeofday(struct timespec *tv)
+int do_settimeofday(const struct timespec *tv)
 {
        struct timespec ts_delta;
        unsigned long flags;
@@ -910,11 +910,6 @@ struct timespec __current_kernel_time(void)
        return xtime;
 }
 
-struct timespec __get_wall_to_monotonic(void)
-{
-       return wall_to_monotonic;
-}
-
 struct timespec current_kernel_time(void)
 {
        struct timespec now;
@@ -974,3 +969,16 @@ void get_xtime_and_monotonic_offset(struct timespec *xtim, struct timespec *wtom
                *wtom = wall_to_monotonic;
        } while (read_seqretry(&xtime_lock, seq));
 }
+
+/**
+ * xtime_update() - advances the timekeeping infrastructure
+ * @ticks:     number of ticks, that have elapsed since the last call.
+ *
+ * Must be called with interrupts disabled.
+ */
+void xtime_update(unsigned long ticks)
+{
+       write_seqlock(&xtime_lock);
+       do_timer(ticks);
+       write_sequnlock(&xtime_lock);
+}