um: fix build without CONFIG_UML_TIME_TRAVEL_SUPPORT
authorJohannes Berg <johannes.berg@intel.com>
Wed, 3 Jul 2019 08:52:01 +0000 (10:52 +0200)
committerRichard Weinberger <richard@nod.at>
Thu, 4 Jul 2019 07:52:18 +0000 (09:52 +0200)
When CONFIG_UML_TIME_TRAVEL_SUPPORT isn't set, the build was broken.
Fix this.

Fixes: 065038706f77 ("um: Support time travel mode")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
arch/um/include/shared/timer-internal.h
arch/um/kernel/process.c

index 5ca74f4..8574338 100644 (file)
@@ -54,6 +54,8 @@ static inline void time_travel_set_timer(enum time_travel_timer_mode mode,
                                         unsigned long long expiry)
 {
 }
+
+#define time_travel_timer_mode TT_TMR_DISABLED
 #endif
 
 #endif
index def2091..67c0d1a 100644 (file)
@@ -213,7 +213,7 @@ static void time_travel_sleep(unsigned long long duration)
        if (time_travel_timer_mode != TT_TMR_DISABLED ||
            time_travel_timer_expiry < next) {
                if (time_travel_timer_mode == TT_TMR_ONESHOT)
-                       time_travel_timer_mode = TT_TMR_DISABLED;
+                       time_travel_set_timer(TT_TMR_DISABLED, 0);
                /*
                 * time_travel_time will be adjusted in the timer
                 * IRQ handler so it works even when the signal