aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/time
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/time')
-rw-r--r--kernel/time/ntp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c
index 5202dde2f0af..580a35028693 100644
--- a/kernel/time/ntp.c
+++ b/kernel/time/ntp.c
@@ -141,10 +141,10 @@ static void ntp_update_offset(long offset)
141 * Select how the frequency is to be controlled 141 * Select how the frequency is to be controlled
142 * and in which mode (PLL or FLL). 142 * and in which mode (PLL or FLL).
143 */ 143 */
144 if (time_status & STA_FREQHOLD || time_reftime == 0)
145 time_reftime = xtime.tv_sec;
146
147 secs = xtime.tv_sec - time_reftime; 144 secs = xtime.tv_sec - time_reftime;
145 if (unlikely(time_status & STA_FREQHOLD || time_reftime == 0))
146 secs = 0;
147
148 time_reftime = xtime.tv_sec; 148 time_reftime = xtime.tv_sec;
149 149
150 offset64 = offset; 150 offset64 = offset;