<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/time/timekeeping.c, branch v2.6.32</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.32</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v2.6.32'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2009-10-11T18:20:58Z</updated>
<entry>
<title>headers: remove sched.h from interrupt.h</title>
<updated>2009-10-11T18:20:58Z</updated>
<author>
<name>Alexey Dobriyan</name>
<email>adobriyan@gmail.com</email>
</author>
<published>2009-10-07T13:09:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d43c36dc6b357fa1806800f18aa30123c747a6d1'/>
<id>urn:sha1:d43c36dc6b357fa1806800f18aa30123c747a6d1</id>
<content type='text'>
After m68k's task_thread_info() doesn't refer to current,
it's possible to remove sched.h from interrupt.h and not break m68k!
Many thanks to Heiko Carstens for allowing this.

Signed-off-by: Alexey Dobriyan &lt;adobriyan@gmail.com&gt;
</content>
</entry>
<entry>
<title>timekeeping: Fix invalid getboottime() value</title>
<updated>2009-08-25T07:09:02Z</updated>
<author>
<name>Hiroshi Shimamoto</name>
<email>h-shimamoto@ct.jp.nec.com</email>
</author>
<published>2009-08-25T06:08:30Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=36d47481b3824b661b464077db95d447984df799'/>
<id>urn:sha1:36d47481b3824b661b464077db95d447984df799</id>
<content type='text'>
Don't use timespec_add_safe() with wall_to_monotonic, because
wall_to_monotonic has negative values which will cause overflow
in timespec_add_safe(). That makes btime in /proc/stat invalid.

Signed-off-by: Hiroshi Shimamoto &lt;h-shimamoto@ct.jp.nec.com&gt;
Cc: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;4A937FDE.4050506@ct.jp.nec.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>time: Introduce CLOCK_REALTIME_COARSE</title>
<updated>2009-08-21T19:43:46Z</updated>
<author>
<name>john stultz</name>
<email>johnstul@us.ibm.com</email>
</author>
<published>2009-08-20T02:13:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=da15cfdae03351c689736f8d142618592e3cebc3'/>
<id>urn:sha1:da15cfdae03351c689736f8d142618592e3cebc3</id>
<content type='text'>
After talking with some application writers who want very fast, but not
fine-grained timestamps, I decided to try to implement new clock_ids
to clock_gettime(): CLOCK_REALTIME_COARSE and CLOCK_MONOTONIC_COARSE
which returns the time at the last tick. This is very fast as we don't
have to access any hardware (which can be very painful if you're using
something like the acpi_pm clocksource), and we can even use the vdso
clock_gettime() method to avoid the syscall. The only trade off is you
only get low-res tick grained time resolution.

This isn't a new idea, I know Ingo has a patch in the -rt tree that made
the vsyscall gettimeofday() return coarse grained time when the
vsyscall64 sysctrl was set to 2. However this affects all applications
on a system.

With this method, applications can choose the proper speed/granularity
trade-off for themselves.

Signed-off-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Andi Kleen &lt;andi@firstfloor.org&gt;
Cc: nikolag@ca.ibm.com
Cc: Darren Hart &lt;dvhltc@us.ibm.com&gt;
Cc: arjan@infradead.org
Cc: jonathan@jonmasters.org
LKML-Reference: &lt;1250734414.6897.5.camel@localhost.localdomain&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;

</content>
</entry>
<entry>
<title>timekeeping: Introduce read_boot_clock</title>
<updated>2009-08-15T08:55:47Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=23970e389e9cee43c4b41023935e1417271708b2'/>
<id>urn:sha1:23970e389e9cee43c4b41023935e1417271708b2</id>
<content type='text'>
Add the new function read_boot_clock to get the exact time the system
has been started. For architectures without support for exact boot
time a new weak function is added that returns 0.  Use the exact boot
time to initialize wall_to_monotonic, or xtime if the read_boot_clock
returned 0.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134811.296703241@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timekeeping: Increase granularity of read_persistent_clock()</title>
<updated>2009-08-15T08:55:46Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d4f587c67fc39e0030ddd718675e252e208da4d7'/>
<id>urn:sha1:d4f587c67fc39e0030ddd718675e252e208da4d7</id>
<content type='text'>
The persistent clock of some architectures (e.g. s390) have a
better granularity than seconds. To reduce the delta between the
host clock and the guest clock in a virtualized system change the 
read_persistent_clock function to return a struct timespec.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134811.013873340@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timekeeping: Update clocksource with stop_machine</title>
<updated>2009-08-15T08:55:46Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:30Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=75c5158f70c065b9704b924503d96e8297838f79'/>
<id>urn:sha1:75c5158f70c065b9704b924503d96e8297838f79</id>
<content type='text'>
update_wall_time calls change_clocksource HZ times per second to check
if a new clock source is available. In close to 100% of all calls
there is no new clock. Replace the tick based check by an update done
with stop_machine.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134810.711836357@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timekeeping: Add timekeeper read_clock helper functions</title>
<updated>2009-08-15T08:55:46Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2ba2a3054fdffc8e6452f4ee120760322a6fbd43'/>
<id>urn:sha1:2ba2a3054fdffc8e6452f4ee120760322a6fbd43</id>
<content type='text'>
Add timekeeper_read_clock_ntp and timekeeper_read_clock_raw and use
them for getnstimeofday, ktime_get, ktime_get_ts and getrawmonotonic.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134810.435105711@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timekeeping: Move NTP adjusted clock multiplier to struct timekeeper</title>
<updated>2009-08-15T08:55:46Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0a54419836254a27baecd9037103171bcbabaf67'/>
<id>urn:sha1:0a54419836254a27baecd9037103171bcbabaf67</id>
<content type='text'>
The clocksource structure has two multipliers, the unmodified multiplier
clock-&gt;mult_orig and the NTP corrected multiplier clock-&gt;mult. The NTP
multiplier is misplaced in the struct clocksource, this is private
information of the timekeeping code. Add the mult field to the struct
timekeeper to contain the NTP corrected value, keep the unmodifed
multiplier in clock-&gt;mult and remove clock-&gt;mult_orig.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134810.149047645@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timekeeping: Add xtime_shift and ntp_error_shift to struct timekeeper</title>
<updated>2009-08-15T08:55:46Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:27Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=23ce72117c714baab794e66c8daf343bf6a912bf'/>
<id>urn:sha1:23ce72117c714baab794e66c8daf343bf6a912bf</id>
<content type='text'>
The xtime_nsec value in the timekeeper structure is shifted by a few
bits to improve precision. This happens to be the same value as the
clock-&gt;shift. To improve readability add xtime_shift to the timekeeper
and use it instead of the clock-&gt;shift. Likewise add ntp_error_shift
and replace all (NTP_SCALE_SHIFT - clock-&gt;shift) expressions.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134809.871899606@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>timekeeping: Introduce struct timekeeper</title>
<updated>2009-08-15T08:55:46Z</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2009-08-14T13:47:26Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=155ec60226ae0ae2aadaa57c951a58a359331030'/>
<id>urn:sha1:155ec60226ae0ae2aadaa57c951a58a359331030</id>
<content type='text'>
Add struct timekeeper to keep the internal values timekeeping.c needs
in regard to the currently selected clock source. This moves the
timekeeping intervals, xtime_nsec and the ntp error value from struct
clocksource to struct timekeeper. The raw_time is removed from the
clocksource as well. It gets treated like xtime as a global variable.
Eventually xtime raw_time should be moved to struct timekeeper.

[ tglx: minor cleanup ]

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Cc: Ingo Molnar &lt;mingo@elte.hu&gt;
Acked-by: John Stultz &lt;johnstul@us.ibm.com&gt;
Cc: Daniel Walker &lt;dwalker@fifo99.com&gt;
LKML-Reference: &lt;20090814134809.613209842@de.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
</feed>
