linux/kernel/time
Arjan van de Ven 8c7b09f43f sched: Update the idle statistics in get_cpu_idle_time_us()
Right now, get_cpu_idle_time_us() only reports the idle
statistics upto the point the CPU entered last idle; not what is
valid right now.

This patch adds an update of the idle statistics to
get_cpu_idle_time_us(), so that calling this function always
returns statistics that are accurate at the point of the call.

This includes resetting the start of the idle time for
accounting purposes to avoid double accounting.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Rik van Riel <riel@redhat.com>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: davej@redhat.com
LKML-Reference: <20100509082323.2d2f1945@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2010-05-09 19:35:26 +02:00
..
clockevents.c clockevent: Don't remove broadcast device when cpu is dead 2010-01-18 14:44:50 +01:00
clocksource.c timekeeping: Prevent oops when GENERIC_TIME=n 2010-03-02 09:22:25 +01:00
jiffies.c clocksource: Cleanup clocksource selection 2009-08-15 10:55:46 +02:00
Kconfig Kconfig: eliminate "def_bool n" constructs 2008-10-16 11:21:31 -07:00
Makefile time: add function to convert between calendar time and broken-down time for universal use 2009-09-24 07:20:56 -07:00
ntp.c ntp: Cleanup xtime references in ntp.c 2010-01-29 10:15:19 +01:00
tick-broadcast.c clockevents: Convert to raw_spinlock 2009-12-14 23:55:34 +01:00
tick-common.c clockevents: Convert to raw_spinlock 2009-12-14 23:55:34 +01:00
tick-internal.h clockevents: Make tick_device_lock static 2009-12-14 23:55:34 +01:00
tick-oneshot.c clockevents: Sanitize min_delta_ns adjustment and prevent overflows 2010-03-12 19:10:29 +01:00
tick-sched.c sched: Update the idle statistics in get_cpu_idle_time_us() 2010-05-09 19:35:26 +02:00
timecompare.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
timeconv.c time: add function to convert between calendar time and broken-down time for universal use 2009-09-24 07:20:56 -07:00
timekeeping.c time: Fix accumulation bug triggered by long delay. 2010-03-23 16:41:01 +01:00
timer_list.c clockevents: Sanitize min_delta_ns adjustment and prevent overflows 2010-03-12 19:10:29 +01:00
timer_stats.c hrtimers: Convert to raw_spinlocks 2009-12-14 23:55:34 +01:00