aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-08-05 20:46:42 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-08-05 20:46:42 -0400
commite7fda6c4c3c1a7d6996dd75fd84670fa0b5d448f (patch)
treedaa51c16462c318b890acf7f01fba5827275dd74 /arch/s390
parent08d69a25714429850cf9ef71f22d8cdc9189d93f (diff)
parent953dec21aed4038464fec02f96a2f1b8701a5bce (diff)
Merge branch 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull timer and time updates from Thomas Gleixner: "A rather large update of timers, timekeeping & co - Core timekeeping code is year-2038 safe now for 32bit machines. Now we just need to fix all in kernel users and the gazillion of user space interfaces which rely on timespec/timeval :) - Better cache layout for the timekeeping internal data structures. - Proper nanosecond based interfaces for in kernel users. - Tree wide cleanup of code which wants nanoseconds but does hoops and loops to convert back and forth from timespecs. Some of it definitely belongs into the ugly code museum. - Consolidation of the timekeeping interface zoo. - A fast NMI safe accessor to clock monotonic for tracing. This is a long standing request to support correlated user/kernel space traces. With proper NTP frequency correction it's also suitable for correlation of traces accross separate machines. - Checkpoint/restart support for timerfd. - A few NOHZ[_FULL] improvements in the [hr]timer code. - Code move from kernel to kernel/time of all time* related code. - New clocksource/event drivers from the ARM universe. I'm really impressed that despite an architected timer in the newer chips SoC manufacturers insist on inventing new and differently broken SoC specific timers. [ Ed. "Impressed"? I don't think that word means what you think it means ] - Another round of code move from arch to drivers. Looks like most of the legacy mess in ARM regarding timers is sorted out except for a few obnoxious strongholds. - The usual updates and fixlets all over the place" * 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (114 commits) timekeeping: Fixup typo in update_vsyscall_old definition clocksource: document some basic timekeeping concepts timekeeping: Use cached ntp_tick_length when accumulating error timekeeping: Rework frequency adjustments to work better w/ nohz timekeeping: Minor fixup for timespec64->timespec assignment ftrace: Provide trace clocks monotonic timekeeping: Provide fast and NMI safe access to CLOCK_MONOTONIC seqcount: Add raw_write_seqcount_latch() seqcount: Provide raw_read_seqcount() timekeeping: Use tk_read_base as argument for timekeeping_get_ns() timekeeping: Create struct tk_read_base and use it in struct timekeeper timekeeping: Restructure the timekeeper some more clocksource: Get rid of cycle_last clocksource: Move cycle_last validation to core code clocksource: Make delta calculation a function wireless: ath9k: Get rid of timespec conversions drm: vmwgfx: Use nsec based interfaces drm: i915: Use nsec based interfaces timekeeping: Provide ktime_get_raw() hangcheck-timer: Use ktime_get_ns() ...
Diffstat (limited to 'arch/s390')
-rw-r--r--arch/s390/Kconfig1
-rw-r--r--arch/s390/kernel/time.c16
2 files changed, 8 insertions, 9 deletions
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index f5af5f6ef0f4..720a11d339eb 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -136,7 +136,6 @@ config S390
136 select HAVE_SYSCALL_TRACEPOINTS 136 select HAVE_SYSCALL_TRACEPOINTS
137 select HAVE_UID16 if 32BIT 137 select HAVE_UID16 if 32BIT
138 select HAVE_VIRT_CPU_ACCOUNTING 138 select HAVE_VIRT_CPU_ACCOUNTING
139 select KTIME_SCALAR if 32BIT
140 select MODULES_USE_ELF_RELA 139 select MODULES_USE_ELF_RELA
141 select NO_BOOTMEM 140 select NO_BOOTMEM
142 select OLD_SIGACTION 141 select OLD_SIGACTION
diff --git a/arch/s390/kernel/time.c b/arch/s390/kernel/time.c
index 0931b110c826..4cef607f3711 100644
--- a/arch/s390/kernel/time.c
+++ b/arch/s390/kernel/time.c
@@ -214,26 +214,26 @@ void update_vsyscall(struct timekeeper *tk)
214{ 214{
215 u64 nsecps; 215 u64 nsecps;
216 216
217 if (tk->clock != &clocksource_tod) 217 if (tk->tkr.clock != &clocksource_tod)
218 return; 218 return;
219 219
220 /* Make userspace gettimeofday spin until we're done. */ 220 /* Make userspace gettimeofday spin until we're done. */
221 ++vdso_data->tb_update_count; 221 ++vdso_data->tb_update_count;
222 smp_wmb(); 222 smp_wmb();
223 vdso_data->xtime_tod_stamp = tk->clock->cycle_last; 223 vdso_data->xtime_tod_stamp = tk->tkr.cycle_last;
224 vdso_data->xtime_clock_sec = tk->xtime_sec; 224 vdso_data->xtime_clock_sec = tk->xtime_sec;
225 vdso_data->xtime_clock_nsec = tk->xtime_nsec; 225 vdso_data->xtime_clock_nsec = tk->tkr.xtime_nsec;
226 vdso_data->wtom_clock_sec = 226 vdso_data->wtom_clock_sec =
227 tk->xtime_sec + tk->wall_to_monotonic.tv_sec; 227 tk->xtime_sec + tk->wall_to_monotonic.tv_sec;
228 vdso_data->wtom_clock_nsec = tk->xtime_nsec + 228 vdso_data->wtom_clock_nsec = tk->tkr.xtime_nsec +
229 + ((u64) tk->wall_to_monotonic.tv_nsec << tk->shift); 229 + ((u64) tk->wall_to_monotonic.tv_nsec << tk->tkr.shift);
230 nsecps = (u64) NSEC_PER_SEC << tk->shift; 230 nsecps = (u64) NSEC_PER_SEC << tk->tkr.shift;
231 while (vdso_data->wtom_clock_nsec >= nsecps) { 231 while (vdso_data->wtom_clock_nsec >= nsecps) {
232 vdso_data->wtom_clock_nsec -= nsecps; 232 vdso_data->wtom_clock_nsec -= nsecps;
233 vdso_data->wtom_clock_sec++; 233 vdso_data->wtom_clock_sec++;
234 } 234 }
235 vdso_data->tk_mult = tk->mult; 235 vdso_data->tk_mult = tk->tkr.mult;
236 vdso_data->tk_shift = tk->shift; 236 vdso_data->tk_shift = tk->tkr.shift;
237 smp_wmb(); 237 smp_wmb();
238 ++vdso_data->tb_update_count; 238 ++vdso_data->tb_update_count;
239} 239}