<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/time/timekeeping.c, branch v2.6.38</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v2.6.38</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v2.6.38'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2011-01-15T20:45:00Z</updated>
<entry>
<title>Merge branches 'core-fixes-for-linus', 'x86-fixes-for-linus', 'timers-fixes-for-linus' and 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip</title>
<updated>2011-01-15T20:45:00Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2011-01-15T20:45:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f9ee7f60d6f37ae0184812b4c59b3869f875768b'/>
<id>urn:sha1:f9ee7f60d6f37ae0184812b4c59b3869f875768b</id>
<content type='text'>
* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  rcu: avoid pointless blocked-task warnings
  rcu: demote SRCU_SYNCHRONIZE_DELAY from kernel-parameter status
  rtmutex: Fix comment about why new_owner can be NULL in wake_futex_pi()

* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86, olpc: Add missing Kconfig dependencies
  x86, mrst: Set correct APB timer IRQ affinity for secondary cpu
  x86: tsc: Fix calibration refinement conditionals to avoid divide by zero
  x86, ia64, acpi: Clean up x86-ism in drivers/acpi/numa.c

* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  timekeeping: Make local variables static
  time: Rename misnamed minsec argument of clocks_calc_mult_shift()

* 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  tracing: Remove syscall_exit_fields
  tracing: Only process module tracepoints once
  perf record: Add "nodelay" mode, disabled by default
  perf sched: Fix list of events, dropping unsupported ':r' modifier
  Revert "perf tools: Emit clearer message for sys_perf_event_open ENOENT return"
  perf top: Fix annotate segv
  perf evsel: Fix order of event list deletion
</content>
</entry>
<entry>
<title>pps: capture MONOTONIC_RAW timestamps as well</title>
<updated>2011-01-13T16:03:21Z</updated>
<author>
<name>Alexander Gordeev</name>
<email>lasaine@lvk.cs.msu.su</email>
</author>
<published>2011-01-13T01:00:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e2c18e49a0d4f822ffc29fb4958943beb1ff08b7'/>
<id>urn:sha1:e2c18e49a0d4f822ffc29fb4958943beb1ff08b7</id>
<content type='text'>
MONOTONIC_RAW clock timestamps are ideally suited for frequency
calculation and also fit well into the original NTP hardpps design.  Now
phase and frequency can be adjusted separately: the former based on
REALTIME clock and the latter based on MONOTONIC_RAW clock.

A new function getnstime_raw_and_real is added to timekeeping subsystem to
capture both timestamps at the same time and atomically.

Signed-off-by: Alexander Gordeev &lt;lasaine@lvk.cs.msu.su&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>timekeeping: Make local variables static</title>
<updated>2011-01-12T11:23:13Z</updated>
<author>
<name>H Hartley Sweeten</name>
<email>hartleys@visionengravers.com</email>
</author>
<published>2011-01-11T23:59:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=afa14e7c553ebe45844d76208f66017a43abd0e2'/>
<id>urn:sha1:afa14e7c553ebe45844d76208f66017a43abd0e2</id>
<content type='text'>
Signed-off-by: H Hartley Sweeten &lt;hsweeten@visionengravers.com&gt;
Cc: John Stultz &lt;johnstul@us.ibm.com&gt;
LKML-Reference: &lt;0D753D10438DA54287A00B027084269764CE0E54B7@AUSP01VMBX24.collaborationhost.net&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;

</content>
</entry>
<entry>
<title>time: Compensate for rounding on odd-frequency clocksources</title>
<updated>2010-10-21T15:30:05Z</updated>
<author>
<name>Kasper Pedersen</name>
<email>kkp2010@kasperkp.dk</email>
</author>
<published>2010-10-20T22:55:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a386b5af8edda1c742ce9f77891e112eefffc005'/>
<id>urn:sha1:a386b5af8edda1c742ce9f77891e112eefffc005</id>
<content type='text'>
When the clocksource is not a multiple of HZ, the clock will be off.  For
acpi_pm, HZ=1000 the error is 127.111 ppm:

The rounding of cycle_interval ends up generating a false error term in
ntp_error accumulation since xtime_interval is not exactly 1/HZ.  So, we
subtract out the error caused by the rounding.

This has been visible since 2.6.32-rc2
	commit a092ff0f90cae22b2ac8028ecd2c6f6c1a9e4601
	time: Implement logarithmic time accumulation
That commit raised NTP_INTERVAL_FREQ and exposed the rounding error.

testing tool: http://n1.taur.dk/permanent/testpmt.c
Also tested with ntpd and a frequency counter.

Signed-off-by: Kasper Pedersen &lt;kkp2010@kasperkp.dk&gt;
Acked-by: john stultz &lt;johnstul@us.ibm.com&gt;
Cc: John Kacur &lt;jkacur@redhat.com&gt;
Cc: Clark Williams &lt;williams@redhat.com&gt;
Cc: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>time: Workaround gcc loop optimization that causes 64bit div errors</title>
<updated>2010-08-13T19:03:24Z</updated>
<author>
<name>John Stultz</name>
<email>johnstul@us.ibm.com</email>
</author>
<published>2010-08-13T18:30:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c7dcf87a6881bf796faee83003163eb3de41a309'/>
<id>urn:sha1:c7dcf87a6881bf796faee83003163eb3de41a309</id>
<content type='text'>
Early 4.3 versions of gcc apparently aggressively optimize the raw
time accumulation loop, replacing it with a divide.

On 32bit systems, this causes the following link errors:
	undefined reference to `__umoddi3'
	undefined reference to `__udivdi3'

The gcc issue has been fixed in 4.4 and greater.

This patch replaces the accumulation loop with a do_div, as suggested
by Linus.

Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
CC: Jason Wessel &lt;jason.wessel@windriver.com&gt;
CC: Larry Finger &lt;Larry.Finger@lwfinger.net&gt;
CC: Ingo Molnar &lt;mingo@elte.hu&gt;
CC: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>timekeeping: Fix overflow in rawtime tv_nsec on 32 bit archs</title>
<updated>2010-08-12T16:53:39Z</updated>
<author>
<name>Jason Wessel</name>
<email>jason.wessel@windriver.com</email>
</author>
<published>2010-08-09T21:20:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=deda2e81961e96be4f2c09328baca4710a2fd1a0'/>
<id>urn:sha1:deda2e81961e96be4f2c09328baca4710a2fd1a0</id>
<content type='text'>
The tv_nsec is a long and when added to the shifted interval it can wrap
and become negative which later causes looping problems in the
getrawmonotonic().  The edge case occurs when the system has slept for
a short period of time of ~2 seconds.

A trace printk of the values in this patch illustrate the problem:

ftrace time stamp: log
43.716079: logarithmic_accumulation: raw: 3d0913 tv_nsec d687faa
43.718513: logarithmic_accumulation: raw: 3d0913 tv_nsec da588bd
43.722161: logarithmic_accumulation: raw: 3d0913 tv_nsec de291d0
46.349925: logarithmic_accumulation: raw: 7a122600 tv_nsec e1f9ae3
46.349930: logarithmic_accumulation: raw: 1e848980 tv_nsec 8831c0e3

The kernel starts looping at 46.349925 in the getrawmonotonic() due to
the negative value from adding the raw value to tv_nsec.

A simple solution is to accumulate into a u64, and then normalize it
to a timespec_t.

Signed-off-by: Jason Wessel &lt;jason.wessel@windriver.com&gt;
 [ Reworked variable names and simplified some of the code. - John ]
Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: H. Peter Anvin &lt;hpa@zytor.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>timekeeping: Make xtime and wall_to_monotonic static</title>
<updated>2010-07-27T10:40:55Z</updated>
<author>
<name>John Stultz</name>
<email>johnstul@us.ibm.com</email>
</author>
<published>2010-07-14T00:56:26Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0fb86b06298b6cd3205cac2e68a499f269282dac'/>
<id>urn:sha1:0fb86b06298b6cd3205cac2e68a499f269282dac</id>
<content type='text'>
This patch makes xtime and wall_to_monotonic static, as planned in
Documentation/feature-removal-schedule.txt. This will allow for
further cleanups to the timekeeping core.

Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
LKML-Reference: &lt;1279068988-21864-10-git-send-email-johnstul@us.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;

</content>
</entry>
<entry>
<title>hrtimer: Cleanup direct access to wall_to_monotonic</title>
<updated>2010-07-27T10:40:55Z</updated>
<author>
<name>John Stultz</name>
<email>johnstul@us.ibm.com</email>
</author>
<published>2010-07-14T00:56:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=8ab4351a4c888016620f43bde605b3d0964af339'/>
<id>urn:sha1:8ab4351a4c888016620f43bde605b3d0964af339</id>
<content type='text'>
Provides an accessor function to replace hrtimer.c's
direct access of wall_to_monotonic.

This will allow wall_to_monotonic to be made static as
planned in Documentation/feature-removal-schedule.txt

Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
LKML-Reference: &lt;1279068988-21864-9-git-send-email-johnstul@us.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timkeeping: Fix update_vsyscall to provide wall_to_monotonic offset</title>
<updated>2010-07-27T10:40:54Z</updated>
<author>
<name>John Stultz</name>
<email>johnstul@us.ibm.com</email>
</author>
<published>2010-07-14T00:56:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7615856ebfee52b080c22d263ca4debbd0df0ac1'/>
<id>urn:sha1:7615856ebfee52b080c22d263ca4debbd0df0ac1</id>
<content type='text'>
update_vsyscall() did not provide the wall_to_monotoinc offset,
so arch specific implementations tend to reference wall_to_monotonic
directly. This limits future cleanups in the timekeeping core, so
this patch fixes the update_vsyscall interface to provide
wall_to_monotonic, allowing wall_to_monotonic to be made static
as planned in Documentation/feature-removal-schedule.txt

Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Anton Blanchard &lt;anton@samba.org&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Tony Luck &lt;tony.luck@intel.com&gt;
LKML-Reference: &lt;1279068988-21864-7-git-send-email-johnstul@us.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>time: Kill off CONFIG_GENERIC_TIME</title>
<updated>2010-07-27T10:40:54Z</updated>
<author>
<name>John Stultz</name>
<email>johnstul@us.ibm.com</email>
</author>
<published>2010-07-14T00:56:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=592913ecb87a9e06f98ddb55b298f1a66bf94c6b'/>
<id>urn:sha1:592913ecb87a9e06f98ddb55b298f1a66bf94c6b</id>
<content type='text'>
Now that all arches have been converted over to use generic time via
clocksources or arch_gettimeoffset(), we can remove the GENERIC_TIME
config option and simplify the generic code.

Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
LKML-Reference: &lt;1279068988-21864-4-git-send-email-johnstul@us.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
</feed>
