diff options
| author | Tony Breeds <[email protected]> | 2007-10-18 03:04:57 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2007-10-18 14:37:20 -0700 |
| commit | 2c6221483169ddd4c04797cd7296ed4fe52fcdd7 (patch) | |
| tree | 1db73f0bf60b036abe995350637a9a3e916c0ec2 /include | |
| parent | 6212e3a388fdda3f19fa660ef5a30edf54d1dcfd (diff) | |
Fix discrepancy between VDSO based gettimeofday() and sys_gettimeofday().
On platforms that copy sys_tz into the vdso (currently only x86_64, soon to
include powerpc), it is possible for the vdso to get out of sync if a user
calls (admittedly unusual) settimeofday(NULL, ptr).
This patch adds a hook for architectures that set
CONFIG_GENERIC_TIME_VSYSCALL to ensure when sys_tz is updated they can also
updatee their copy in the vdso.
Signed-off-by: Tony Breeds <[email protected]>
Cc: Andi Kleen <[email protected]>
Cc: Tony Luck <[email protected]>
Acked-by: John Stultz <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/clocksource.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h index 16ea3374dddf..107787aacb64 100644 --- a/include/linux/clocksource.h +++ b/include/linux/clocksource.h @@ -221,10 +221,15 @@ extern void clocksource_resume(void); #ifdef CONFIG_GENERIC_TIME_VSYSCALL extern void update_vsyscall(struct timespec *ts, struct clocksource *c); +extern void update_vsyscall_tz(void); #else static inline void update_vsyscall(struct timespec *ts, struct clocksource *c) { } + +static inline void update_vsyscall_tz(void) +{ +} #endif #endif /* _LINUX_CLOCKSOURCE_H */ |