]> git.baikalelectronics.ru Git - kernel.git/commit
clocksource: Load the ACPI PM clocksource asynchronously
authorArjan van de Ven <arjan@linux.intel.com>
Tue, 31 Jan 2012 04:23:30 +0000 (20:23 -0800)
committerJohn Stultz <john.stultz@linaro.org>
Thu, 2 Feb 2012 02:39:46 +0000 (18:39 -0800)
commit5592580b82a981079a7e86befed6e34d5ad55cd3
tree31fd0675057bb14e3dcff26d585fd512614b181b
parentb1aebae683a858fea17bd1f88d3dd93a8c33a694
clocksource: Load the ACPI PM clocksource asynchronously

The ACPI clocksource takes quite some time to initialize,
and this increases the boot time of the kernel for a
double digit percentage. This while almost all modern
systems will be using the HPET already anyway.

This patch turns the clocksource loading into an asynchronous
operation; which means it won't hold up the boot while
still becoming available normally.

To make this work well, an udelay() had to be turned into an
usleep_range() so that on UP systems, we yield the CPU to
regular boot tasks instead of spinning.

CC: John Stultz <johnstul@us.ibm.com>
CC: Thomas Gleixner <tglx@linutronix.de>
CC: Len Brown <lenb@kernel.org>
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
drivers/clocksource/acpi_pm.c