linux/include
Thomas Gleixner dce48a84ad sched, timers: move calc_load() to scheduler
Dimitri Sivanich noticed that xtime_lock is held write locked across
calc_load() which iterates over all online CPUs. That can cause long
latencies for xtime_lock readers on large SMP systems. 

The load average calculation is an rough estimate anyway so there is
no real need to protect the readers vs. the update. It's not a problem
when the avenrun array is updated while a reader copies the values.

Instead of iterating over all online CPUs let the scheduler_tick code
update the number of active tasks shortly before the avenrun update
happens. The avenrun update itself is handled by the CPU which calls
do_timer().

[ Impact: reduce xtime_lock write locked section ]

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Peter Zijlstra <peterz@infradead.org>
2009-05-15 15:32:45 +02:00
..
acpi Merge branch 'drm-intel-next' of git://git.kernel.org/pub/scm/linux/kernel/git/anholt/drm-intel 2009-04-28 17:21:20 -07:00
asm-generic Eliminate thousands of warnings with gcc 3.2 build 2009-05-06 16:36:09 -07:00
crypto crypto: zlib - New zlib crypto module, using pcomp 2009-03-04 15:16:19 +08:00
drm drm/i915: add support for G41 chipset 2009-04-21 17:22:53 -07:00
keys
linux sched, timers: move calc_load() to scheduler 2009-05-15 15:32:45 +02:00
math-emu
media V4L/DVB (11381): ivtv/cx18: remove VIDIOC_INT_S_AUDIO_ROUTING debug support. 2009-04-06 21:44:28 -03:00
mtd make MTD headers use strict integer types 2009-03-26 18:14:17 +01:00
net Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 2009-05-05 08:26:10 -07:00
pcmcia
rdma Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6 2009-03-26 15:54:36 -07:00
rxrpc
scsi PM/Hibernate: Wait for SCSI devices scan to complete during resume 2009-04-13 11:37:07 -07:00
sound Merge branch 'fix' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6 2009-04-20 14:03:04 +01:00
trace tracing/syscalls: use a dedicated file header 2009-04-09 05:43:32 +02:00
video include/video/cyblafb.h: remove it, it's unused 2009-04-13 15:04:30 -07:00
xen
Kbuild