<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/time/tick-internal.h, branch v3.1-rc2</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/kernel/time/tick-internal.h?h=v3.1-rc2</id>
<link rel='self' href='https://git.amat.us/linux/atom/kernel/time/tick-internal.h?h=v3.1-rc2'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2011-03-16T01:53:35Z</updated>
<entry>
<title>Merge branch 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip</title>
<updated>2011-03-16T01:53:35Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2011-03-16T01:53:35Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=420c1c572d4ceaa2f37b6311b7017ac6cf049fe2'/>
<id>urn:sha1:420c1c572d4ceaa2f37b6311b7017ac6cf049fe2</id>
<content type='text'>
* 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (62 commits)
  posix-clocks: Check write permissions in posix syscalls
  hrtimer: Remove empty hrtimer_init_hres_timer()
  hrtimer: Update hrtimer-&gt;state documentation
  hrtimer: Update base[CLOCK_BOOTTIME].offset correctly
  timers: Export CLOCK_BOOTTIME via the posix timers interface
  timers: Add CLOCK_BOOTTIME hrtimer base
  time: Extend get_xtime_and_monotonic_offset() to also return sleep
  time: Introduce get_monotonic_boottime and ktime_get_boottime
  hrtimers: extend hrtimer base code to handle more then 2 clockids
  ntp: Remove redundant and incorrect parameter check
  mn10300: Switch do_timer() to xtimer_update()
  posix clocks: Introduce dynamic clocks
  posix-timers: Cleanup namespace
  posix-timers: Add support for fd based clocks
  x86: Add clock_adjtime for x86
  posix-timers: Introduce a syscall for clock tuning.
  time: Splitout compat timex accessors
  ntp: Add ADJ_SETOFFSET mode bit
  time: Introduce timekeeping_inject_offset
  posix-timer: Update comment
  ...

Fix up new system-call-related conflicts in
	arch/x86/ia32/ia32entry.S
	arch/x86/include/asm/unistd_32.h
	arch/x86/include/asm/unistd_64.h
	arch/x86/kernel/syscall_table_32.S
(name_to_handle_at()/open_by_handle_at() vs clock_adjtime()), and some
due to movement of get_jiffies_64() in:
	kernel/time.c
</content>
</entry>
<entry>
<title>clockevents: Prevent oneshot mode when broadcast device is periodic</title>
<updated>2011-02-26T08:45:28Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2011-02-25T21:34:23Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=3a142a0672b48a853f00af61f184c7341ac9c99d'/>
<id>urn:sha1:3a142a0672b48a853f00af61f184c7341ac9c99d</id>
<content type='text'>
When the per cpu timer is marked CLOCK_EVT_FEAT_C3STOP, then we only
can switch into oneshot mode, when the backup broadcast device
supports oneshot mode as well. Otherwise we would try to switch the
broadcast device into an unsupported mode unconditionally. This went
unnoticed so far as the current available broadcast devices support
oneshot mode. Seth unearthed this problem while debugging and working
around an hpet related BIOS wreckage.

Add the necessary check to tick_is_oneshot_available().

Reported-and-tested-by: Seth Forshee &lt;seth.forshee@canonical.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
LKML-Reference: &lt;alpine.LFD.2.00.1102252231200.2701@localhost6.localdomain6&gt;
Cc: stable@kernel.org # .21 -&gt;
</content>
</entry>
<entry>
<title>time: Fix legacy arch fallout</title>
<updated>2011-02-01T08:46:47Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2011-02-01T08:34:58Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7cf37e87dd2cfa17a64f28ea7f31eed4525f79e4'/>
<id>urn:sha1:7cf37e87dd2cfa17a64f28ea7f31eed4525f79e4</id>
<content type='text'>
The xtime/dotimer cleanup broke architectures which do not implement
clockevents. Time to send out another __do_IRQ threat.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reported-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Cc: Torben Hohn &lt;torbenh@gmx.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: johnstul@us.ibm.com
Cc: yong.zhang0@gmail.com
Cc: hch@infradead.org
LKML-Reference: &lt;20110127145905.23248.30458.stgit@localhost&gt;
Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>time: Make do_timer() and xtime_lock local to kernel/time/</title>
<updated>2011-01-31T18:26:50Z</updated>
<author>
<name>Torben Hohn</name>
<email>torbenh@gmx.de</email>
</author>
<published>2011-01-27T15:00:32Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=e2830b5c1b2b2217894370a3b95af87d4a958401'/>
<id>urn:sha1:e2830b5c1b2b2217894370a3b95af87d4a958401</id>
<content type='text'>
All callers of do_timer() are converted to xtime_update(). The only
users of xtime_lock are in kernel/time/. Make both local to
kernel/time/ and remove them from the global header files.

[ tglx: Reuse tick-internal.h instead of creating another local header
  	file. Massaged changelog ]

Signed-off-by: Torben Hohn &lt;torbenh@gmx.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: johnstul@us.ibm.com
Cc: yong.zhang0@gmail.com
Cc: hch@infradead.org
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>clockevents: Make tick_device_lock static</title>
<updated>2009-12-14T22:55:34Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2009-12-08T11:49:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d192c47f25daa98996c7eae543d8a27e41247ec2'/>
<id>urn:sha1:d192c47f25daa98996c7eae543d8a27e41247ec2</id>
<content type='text'>
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Acked-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Acked-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>NOHZ: restart tick device from irq_enter()</title>
<updated>2008-10-17T16:13:38Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2008-10-17T08:01:23Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=fb02fbc14d17837b4b7b02dbb36142c16a7bf208'/>
<id>urn:sha1:fb02fbc14d17837b4b7b02dbb36142c16a7bf208</id>
<content type='text'>
We did not restart the tick device from irq_enter() to avoid double
reprogramming and extra events in the return immediate to idle case.

But long lasting softirqs can lead to a situation where jiffies become
stale:

idle()
  tick stopped (reprogrammed to next pending timer)
  halt()
   interrupt
     jiffies updated from irq_enter()
     interrupt handler
     softirq function 1 runs 20ms
     softirq function 2 arms a 10ms timer with a stale jiffies value
     jiffies updated from irq_exit()
     timer wheel has now an already expired timer
     (the one added in function 2)
     timer fires and timer softirq runs

This was discovered when debugging a timer problem which happend only
when the ath5k driver is active. The debugging proved that there is a
softirq function running for more than 20ms, which is a bug by itself.

To solve this we restart the tick timer right from irq_enter(), but do
not go through the other functions which are necessary to return from
idle when need_resched() is set.

Reported-by: Elias Oltmanns &lt;eo@nebensachen.de&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Tested-by: Elias Oltmanns &lt;eo@nebensachen.de&gt;
</content>
</entry>
<entry>
<title>timers: fix build error in !oneshot case</title>
<updated>2008-09-23T10:57:00Z</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@elte.hu</email>
</author>
<published>2008-09-23T11:00:57Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f8e256c687eb53850685747757c8d75e58756e15'/>
<id>urn:sha1:f8e256c687eb53850685747757c8d75e58756e15</id>
<content type='text'>
 kernel/time/tick-common.c: In function ‘tick_setup_periodic’:
 kernel/time/tick-common.c:113: error: implicit declaration of function ‘tick_broadcast_oneshot_active’

Signed-off-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>clockevents: prevent mode mismatch on cpu online</title>
<updated>2008-09-23T09:38:53Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2008-09-22T17:04:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=27ce4cb4a0c7cf59b9a9952266883862f2e4c99f'/>
<id>urn:sha1:27ce4cb4a0c7cf59b9a9952266883862f2e4c99f</id>
<content type='text'>
Impact: timer hang on CPU online observed on AMD C1E systems

When a CPU is brought online then the broadcast machinery can
be in the one shot state already. Check this and setup the timer 
device of the new CPU in one shot mode so the broadcast code
can pick up the next_event value correctly.

Another AMD C1E oddity, as we switch to broadcast immediately and
not after the full bring up via the ACPI cpu idle code.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>clockevents: prevent cpu online to interfere with nohz</title>
<updated>2008-09-23T09:38:52Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2008-09-22T16:46:37Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=6441402b1f173fa38e561d3cee7c01c32e5281ad'/>
<id>urn:sha1:6441402b1f173fa38e561d3cee7c01c32e5281ad</id>
<content type='text'>
Impact: rare hang which can be triggered on CPU online.

tick_do_timer_cpu keeps track of the CPU which updates jiffies
via do_timer. The value -1 is used to signal, that currently no
CPU is doing this. There are two cases, where the variable can 
have this state:

 boot:
    necessary for systems where the boot cpu id can be != 0

 nohz long idle sleep:
    When the CPU which did the jiffies update last goes into
    a long idle sleep it drops the update jiffies duty so
    another CPU which is not idle can pick it up and keep
    jiffies going.

Using the same value for both situations is wrong, as the CPU online
code can see the -1 state when the timer of the newly onlined CPU is
setup. The setup for a newly onlined CPU goes through periodic mode
and can pick up the do_timer duty without being aware of the nohz /
highres mode of the already running system.

Use two separate states and make them constants to avoid magic
numbers confusion. 

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>clockevents: make device shutdown robust</title>
<updated>2008-09-16T20:47:02Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2008-09-16T18:32:50Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=2344abbcbdb82140050e8be29d3d55e4f6fe860b'/>
<id>urn:sha1:2344abbcbdb82140050e8be29d3d55e4f6fe860b</id>
<content type='text'>
The device shut down does not cleanup the next_event variable of the
clock event device. So when the device is reactivated the possible
stale next_event value can prevent the device to be reprogrammed as it
claims to wait on a event already.

This is the root cause of the resurfacing suspend/resume problem,
where systems need key press to come back to life.

Fix this by setting next_event to KTIME_MAX when the device is shut
down. Use a separate function for shutdown which takes care of that
and only keep the direct set mode call in the broadcast code, where we
can not touch the next_event value.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
</feed>
