summaryrefslogtreecommitdiffstats
path: root/kernel/time
diff options
context:
space:
mode:
authorJohn Stultz <john.stultz@linaro.org>2011-11-14 13:06:21 -0800
committerJohn Stultz <john.stultz@linaro.org>2012-01-26 19:44:20 -0800
commit8357929e6ae3661d5a3a7378a717f29873ea18c6 (patch)
tree49cee3ead7619a7a7a8ae2dd01c4a8b1f9e8add9 /kernel/time
parent70471f2f061d59375e959b4e7d47ee62121babb1 (diff)
downloadblackbird-op-linux-8357929e6ae3661d5a3a7378a717f29873ea18c6.tar.gz
blackbird-op-linux-8357929e6ae3661d5a3a7378a717f29873ea18c6.zip
ntp: Cleanup timex.h
Move ntp_sycned to ntp.c and mark time_status as static. Also yank function declaration for non-existant function. CC: Thomas Gleixner <tglx@linutronix.de> CC: Eric Dumazet <eric.dumazet@gmail.com> CC: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org>
Diffstat (limited to 'kernel/time')
-rw-r--r--kernel/time/ntp.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c
index f6117a4c7cb8..ae7e13607d91 100644
--- a/kernel/time/ntp.c
+++ b/kernel/time/ntp.c
@@ -49,7 +49,7 @@ static struct hrtimer leap_timer;
static int time_state = TIME_OK;
/* clock status bits: */
-int time_status = STA_UNSYNC;
+static int time_status = STA_UNSYNC;
/* TAI offset (secs): */
static long time_tai;
@@ -233,6 +233,17 @@ static inline void pps_fill_timex(struct timex *txc)
#endif /* CONFIG_NTP_PPS */
+
+/**
+ * ntp_synced - Returns 1 if the NTP status is not UNSYNC
+ *
+ */
+static inline int ntp_synced(void)
+{
+ return !(time_status & STA_UNSYNC);
+}
+
+
/*
* NTP methods:
*/
OpenPOWER on IntegriCloud