remarkable-linux/include
Thomas Gleixner eaad084bb0 NOHZ: prevent multiplication overflow - stop timer for huge timeouts
get_next_timer_interrupt() returns a delta of (LONG_MAX > 1) in case
there is no timer pending. On 64 bit machines this results in a
multiplication overflow in tick_nohz_stop_sched_tick().

Reported by: Dave Miller <davem@davemloft.net>

Make the return value a constant and limit the return value to a 32 bit
value.

When the max timeout value is returned, we can safely stop the tick
timer device. The max jiffies delta results in a 12 days timeout for
HZ=1000.

In the long term the get_next_timer_interrupt() code needs to be
reworked to return ktime instead of jiffies, but we have to wait until
the last users of the original NO_IDLE_HZ code are converted.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-29 18:11:10 -07:00
..
acpi acpi: fix potential call to a freed memory section. 2007-05-17 05:23:04 -07:00
asm-alpha
asm-arm Merge master.kernel.org:/home/rmk/linux-2.6-arm 2007-05-21 10:00:22 -07:00
asm-arm26
asm-avr32
asm-blackfin Blackfin arch: Change NO_ACCESS_CHECK to ACCESS_CHECK 2007-05-21 09:50:23 -07:00
asm-cris
asm-frv
asm-generic Don't call a warnign a bug. It's a warning. 2007-05-24 10:13:43 -07:00
asm-h8300
asm-i386 i386: fix early usage of atomic_add_return and local_add_return on real i386 2007-05-23 20:14:15 -07:00
asm-ia64 [IA64] Cleanup acpi header to reuse the generic _PDC defines 2007-05-24 10:15:06 -07:00
asm-m32r
asm-m68k
asm-m68knommu
asm-mips Detach sched.h from mm.h 2007-05-21 09:18:19 -07:00
asm-parisc Detach sched.h from mm.h 2007-05-21 09:18:19 -07:00
asm-powerpc Detach sched.h from mm.h 2007-05-21 09:18:19 -07:00
asm-ppc
asm-s390 [S390] Wire up signald, timerfd and eventfd syscalls. 2007-05-21 11:25:28 +02:00
asm-sh sh: Fix dreamcast build for IRQ changes. 2007-05-21 15:10:04 +09:00
asm-sh64
asm-sparc [SPARC]: Emulate cmpxchg like parisc 2007-05-29 02:51:13 -07:00
asm-sparc64 [SPARC64]: Fill holes in hypervisor APIs and fix KTSB registry. 2007-05-29 02:52:15 -07:00
asm-um
asm-v850
asm-x86_64 Detach sched.h from mm.h 2007-05-21 09:18:19 -07:00
asm-xtensa
crypto
keys
linux NOHZ: prevent multiplication overflow - stop timer for huge timeouts 2007-05-29 18:11:10 -07:00
math-emu
media
mtd
net [XFRM]: Allow packet drops during larval state resolution. 2007-05-24 18:17:54 -07:00
pcmcia
rdma Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband 2007-05-21 16:19:32 -07:00
rxrpc
scsi
sound [ALSA] version 1.0.14rc4 2007-05-16 11:45:47 +02:00
video
Kbuild