]> git.baikalelectronics.ru Git - kernel.git/commit
nohz: Make idle/iowait counter update conditional
authorMichal Hocko <mhocko@suse.cz>
Wed, 24 Aug 2011 07:39:30 +0000 (09:39 +0200)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 8 Sep 2011 09:10:55 +0000 (11:10 +0200)
commit36c352a9b51587c21d2a17d39e8e3ab620503101
tree5de69591f64e995737a62cf26d8bb3a927b27d79
parentc3b4be1760a5ed47a4acfdd30927f6ccb06378fc
nohz: Make idle/iowait counter update conditional

get_cpu_{idle,iowait}_time_us update idle/iowait counters
unconditionally if the given CPU is in the idle loop.

This doesn't work well outside of CPU governors which are singletons
so nobody (except for IRQ) can race with them.

We will need to use both functions from /proc/stat handler to properly
handle nohz idle/iowait times.

Make the update depend on a non NULL last_update_time argument.

Signed-off-by: Michal Hocko <mhocko@suse.cz>
Cc: Dave Jones <davej@redhat.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Link: http://lkml.kernel.org/r/11f23179472635ce52e78921d47a20216b872f23.1314172057.git.mhocko@suse.cz
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
kernel/time/tick-sched.c