mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v4 1/4] time: Add needed macros for timekeeping_inject_sleeptime64()
@ 2015-02-15 13:09 Xunlei Pang
  2015-02-15 13:09 ` [PATCH v4 2/4] time: Fix a bug in timekeeping_suspend() with no persistent clock Xunlei Pang
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Xunlei Pang @ 2015-02-15 13:09 UTC (permalink / raw)
  To: linux-kernel
  Cc: rtc-linux, Thomas Gleixner, Alessandro Zummo, John Stultz,
	Arnd Bergmann, Peter Zijlstra, Xunlei Pang

From: Xunlei Pang <pang.xunlei@linaro.org>

timekeeping_inject_sleeptime64() is only used by RTC suspend/resume,
so embrace it in RTC related macros.

Signed-off-by: Xunlei Pang <pang.xunlei@linaro.org>
---
 kernel/time/timekeeping.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
index b124af2..d78a528 100644
--- a/kernel/time/timekeeping.c
+++ b/kernel/time/timekeeping.c
@@ -1125,6 +1125,9 @@ static void __timekeeping_inject_sleeptime(struct timekeeper *tk,
 	tk_debug_account_sleep_time(delta);
 }
 
+#if defined(CONFIG_RTC_CLASS) && \
+	defined(CONFIG_PM_SLEEP) && \
+	defined(CONFIG_RTC_HCTOSYS_DEVICE)
 /**
  * timekeeping_inject_sleeptime64 - Adds suspend interval to timeekeeping values
  * @delta: pointer to a timespec64 delta value
@@ -1162,6 +1165,7 @@ void timekeeping_inject_sleeptime64(struct timespec64 *delta)
 	/* signal hrtimers about time change */
 	clock_was_set();
 }
+#endif
 
 /**
  * timekeeping_resume - Resumes the generic timekeeping subsystem.
-- 
1.9.1



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-02-26  5:08 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-15 13:09 [PATCH v4 1/4] time: Add needed macros for timekeeping_inject_sleeptime64() Xunlei Pang
2015-02-15 13:09 ` [PATCH v4 2/4] time: Fix a bug in timekeeping_suspend() with no persistent clock Xunlei Pang
2015-02-15 13:09 ` [PATCH v4 3/4] time: rtc: Don't bother into rtc_resume() for the nonstop clocksource Xunlei Pang
2015-02-26  5:00   ` John Stultz
2015-02-15 13:09 ` [PATCH v4 4/4] rtc: Remove redundant rtc_valid_tm() from rtc_resume() Xunlei Pang
2015-02-26  5:08 ` [PATCH v4 1/4] time: Add needed macros for timekeeping_inject_sleeptime64() John Stultz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®