]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] i386: add idle notifier
authorStephane Eranian <eranian@hpl.hp.com>
Tue, 13 Feb 2007 12:26:22 +0000 (13:26 +0100)
committerAndi Kleen <andi@basil.nowhere.org>
Tue, 13 Feb 2007 12:26:22 +0000 (13:26 +0100)
commitf97e092bf29067b74a3711300c505f72747f73b0
treeb74849c0a55f3eb4458e7399c6d30a0f8b270d58
parentee0b1f229317c3b841a1fb6605aacc3b42cc5433
[PATCH] i386: add idle notifier

Add a notifier mechanism to the low level idle loop.  You can register a
callback function which gets invoked on entry and exit from the low level idle
loop.  The low level idle loop is defined as the polling loop, low-power call,
or the mwait instruction.  Interrupts processed by the idle thread are not
considered part of the low level loop.

The notifier can be used to measure precisely how much is spent in useless
execution (or low power mode).  The perfmon subsystem uses it to turn on/off
monitoring.

Signed-off-by: stephane eranian <eranian@hpl.hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Andi Kleen <ak@suse.de>
arch/i386/kernel/apic.c
arch/i386/kernel/cpu/mcheck/p4.c
arch/i386/kernel/irq.c
arch/i386/kernel/process.c
arch/i386/kernel/smp.c
include/asm-i386/idle.h [new file with mode: 0644]
include/asm-i386/processor.h