diff options
| author | Thomas Gleixner <tglx@linutronix.de> | 2013-02-14 13:46:10 -0500 |
|---|---|---|
| committer | Thomas Gleixner <tglx@linutronix.de> | 2013-02-14 13:46:10 -0500 |
| commit | 9f4646d28362bc424b8a4c7d09ea1c2f1759371a (patch) | |
| tree | 0ff9dc36f1ef598736725f3eb30e164128d39774 /kernel/time.c | |
| parent | 86c8ead593305915729a7b67f738832764fb4ba7 (diff) | |
| parent | 84e345e4e209cbe796c88fa2ad1732d7121ec100 (diff) | |
Merge branch 'fortglx/3.9/time' of git://git.linaro.org/people/jstultz/linux into timers/core
Diffstat (limited to 'kernel/time.c')
| -rw-r--r-- | kernel/time.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/kernel/time.c b/kernel/time.c index d226c6a3fd28..c2a27dd93142 100644 --- a/kernel/time.c +++ b/kernel/time.c | |||
| @@ -115,6 +115,12 @@ SYSCALL_DEFINE2(gettimeofday, struct timeval __user *, tv, | |||
| 115 | } | 115 | } |
| 116 | 116 | ||
| 117 | /* | 117 | /* |
| 118 | * Indicates if there is an offset between the system clock and the hardware | ||
| 119 | * clock/persistent clock/rtc. | ||
| 120 | */ | ||
| 121 | int persistent_clock_is_local; | ||
| 122 | |||
| 123 | /* | ||
| 118 | * Adjust the time obtained from the CMOS to be UTC time instead of | 124 | * Adjust the time obtained from the CMOS to be UTC time instead of |
| 119 | * local time. | 125 | * local time. |
| 120 | * | 126 | * |
| @@ -135,6 +141,8 @@ static inline void warp_clock(void) | |||
| 135 | struct timespec adjust; | 141 | struct timespec adjust; |
| 136 | 142 | ||
| 137 | adjust = current_kernel_time(); | 143 | adjust = current_kernel_time(); |
| 144 | if (sys_tz.tz_minuteswest != 0) | ||
| 145 | persistent_clock_is_local = 1; | ||
| 138 | adjust.tv_sec += sys_tz.tz_minuteswest * 60; | 146 | adjust.tv_sec += sys_tz.tz_minuteswest * 60; |
| 139 | do_settimeofday(&adjust); | 147 | do_settimeofday(&adjust); |
| 140 | } | 148 | } |
