summaryrefslogtreecommitdiff
path: root/include/linux/hrtimer.h
diff options
context:
space:
mode:
authorAnna-Maria Gleixner <anna-maria@linutronix.de>2017-12-21 11:41:39 +0100
committerIngo Molnar <mingo@kernel.org>2018-01-16 02:35:46 +0100
commitc272ca58c3ec5631f4ab507489d9477f74efe645 (patch)
treee117843b4055a931b4973dbf270f3a16b07b6f32 /include/linux/hrtimer.h
parent63e2ed3659752a4850e0ef3a07f809988fcd74a4 (diff)
downloadlwn-c272ca58c3ec5631f4ab507489d9477f74efe645.tar.gz
lwn-c272ca58c3ec5631f4ab507489d9477f74efe645.zip
hrtimer: Switch 'for' loop to _ffs() evaluation
Looping over all clock bases to find active bits is suboptimal if not all bases are active. Avoid this by converting it to a __ffs() evaluation. The functionallity is outsourced into its own function and is called via a macro as suggested by Peter Zijlstra. Suggested-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Cc: Christoph Hellwig <hch@lst.de> Cc: John Stultz <john.stultz@linaro.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: keescook@chromium.org Link: http://lkml.kernel.org/r/20171221104205.7269-11-anna-maria@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/hrtimer.h')
0 files changed, 0 insertions, 0 deletions