linux/drivers
Preeti U Murthy ba8f20c2eb cpuidle: Handle clockevents_notify(BROADCAST_ENTER) failure
Some archs set the CPUIDLE_FLAG_TIMER_STOP flag for idle states in which the
local timers stop. The cpuidle_idle_call() currently handles such idle states
by calling into the broadcast framework so as to wakeup CPUs at their next
wakeup event. With the hrtimer mode of broadcast, the BROADCAST_ENTER call
into the broadcast frameowork can fail for archs that do not have an external
clock device to handle wakeups and the CPU in question has thus to be made
the stand by CPU. This patch handles such cases by failing the call into
cpuidle so that the arch can take some default action. The arch will certainly
not enter a similar idle state because a failed cpuidle call will also implicitly
indicate that the broadcast framework has not registered this CPU to be woken up.
Hence we are safe if we fail the cpuidle call.

In the process move the functions that trace idle statistics just before and
after the entry and exit into idle states respectively. In other
scenarios where the call to cpuidle fails, we end up not tracing idle
entry and exit since a decision on an idle state could not be taken. Similarly
when the call to broadcast framework fails, we skip tracing idle statistics
because we are in no further position to take a decision on an alternative
idle state to enter into.

Signed-off-by: Preeti U Murthy <preeti@linux.vnet.ibm.com>
Cc: deepthi@linux.vnet.ibm.com
Cc: paulmck@linux.vnet.ibm.com
Cc: fweisbec@gmail.com
Cc: paulus@samba.org
Cc: srivatsa.bhat@linux.vnet.ibm.com
Cc: svaidy@linux.vnet.ibm.com
Cc: peterz@infradead.org
Cc: benh@kernel.crashing.org
Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Cc: linuxppc-dev@lists.ozlabs.org
Link: http://lkml.kernel.org/r/20140207080652.17187.66344.stgit@preeti.in.ibm.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2014-02-07 15:34:29 +01:00
..
accessibility
acpi Merge branches 'acpi-processor', 'acpi-hotplug', 'acpi-init', 'acpi-pm' and 'acpica' 2014-01-29 11:47:18 +01:00
amba
ata ACPI and power management updates for 3.14-rc1 2014-01-24 15:51:02 -08:00
atm atm: slight optimization of addr compare 2013-12-26 13:31:34 -05:00
auxdisplay
base regmap: Updates for v3.14 2014-01-25 13:18:00 -08:00
bcma Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2014-01-30 17:20:32 -08:00
block Bug-fixes: 2014-01-31 08:38:18 -08:00
bluetooth Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next 2014-01-08 13:44:29 -05:00
bus drivers: bus: fix CCI driver kcalloc call parameters swap 2014-01-31 15:15:13 -08:00
cdrom Merge branch 'for-3.14/drivers' of git://git.kernel.dk/linux-block 2014-01-30 11:40:10 -08:00
char ipmi: Add missing rv in ipmi_parisc_probe() 2014-01-30 10:02:54 -08:00
clk The second half of the clock framework pull requeust for 3.14 is 2014-01-28 18:44:53 -08:00
clocksource clocksource: kona: Add basic use of external clock 2014-01-31 21:04:01 -08:00
connector
cpufreq ACPI and power management fixes and cleanups for 3.14-rc1 2014-01-31 09:23:52 -08:00
cpuidle cpuidle: Handle clockevents_notify(BROADCAST_ENTER) failure 2014-02-07 15:34:29 +01:00
crypto ARM: driver updates for 3.14 2014-01-23 18:49:36 -08:00
dca
devfreq Merge branches 'pm-cpufreq' and 'pm-devfreq' 2014-01-29 11:48:23 +01:00
dio
dma Merge branch 'for-linus' of git://git.infradead.org/users/vkoul/slave-dma 2014-01-29 20:27:23 -08:00
edac Merge branch 'x86-ras-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2014-01-20 12:10:27 -08:00
eisa Revert "EISA: Initialize device before its resources" 2014-01-17 14:57:29 -07:00
extcon extcon: gpio: Add power resume support 2014-01-09 09:53:30 +09:00
firewire firewire: Enable remote DMA above 4 GB 2014-01-20 01:11:13 +01:00
firmware firmware/google: drop 'select EFI' to avoid recursive dependency 2014-01-27 21:02:40 -08:00
fmc
gpio ARM: driver updates for 3.14 2014-01-23 18:49:36 -08:00
gpu Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2014-01-29 20:49:12 -08:00
hid Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media 2014-01-31 09:31:14 -08:00
hsi
hv hyperv: Add support for physically discontinuous receive buffer 2014-01-27 16:40:45 -08:00
hwmon hwmon: Fix SENSORS_TMP102 dependencies to eliminate build errors 2014-02-02 17:59:07 +01:00
hwspinlock
i2c Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux 2014-01-29 19:56:20 -08:00
ide drivers: ide: Include appropriate header file in ide-pio-blacklist.c 2014-01-28 23:35:09 -08:00
idle ACPI and power management updates for 3.14-rc1 2014-01-24 15:51:02 -08:00
iio Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2014-01-22 21:21:55 -08:00
infiniband Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2014-01-31 15:31:23 -08:00
input Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2014-01-24 17:17:30 -08:00
iommu IOMMU Updates for Linux v3.14 2014-01-29 20:00:13 -08:00
ipack
irqchip mvebu fixes for v3.13 (incremental #2) 2014-01-31 14:59:28 -08:00
isdn Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-01-25 11:17:34 -08:00
leds Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds 2014-01-28 18:53:01 -08:00
lguest
macintosh Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc 2014-01-27 21:11:26 -08:00
mailbox drivers/mailbox/omap: make mbox->irq signed for error handling 2014-01-23 16:36:53 -08:00
md Merge branch 'for-3.14/drivers' of git://git.kernel.dk/linux-block 2014-01-30 11:40:10 -08:00
media Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media 2014-01-31 09:31:14 -08:00
memory
memstick drivers/memstick/host/rtsx_pci_ms.c: fix ms card data transfer bug 2014-01-23 16:37:04 -08:00
message Merge branch 'for-3.14/core' of git://git.kernel.dk/linux-block 2014-01-30 11:19:05 -08:00
mfd regulator: Updates for v3.14 2014-01-25 13:19:10 -08:00
misc Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging 2014-01-29 18:56:27 -08:00
mmc MMC highlights for 3.14: 2014-01-26 11:00:41 -08:00
mtd * Improve the NOR erasure quirk - now it tries to do as little writes as 2014-01-30 20:04:09 -08:00
net Merge branch 'akpm' (patches from Andrew Morton) 2014-01-30 18:44:44 -08:00
nfc NFC: nfcmrvl: Fix possible memory leak issue 2014-01-09 01:27:20 +01:00
ntb
nubus
of Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-01-25 11:17:34 -08:00
oprofile
parisc
parport TTY/Serial driver patches for 3.14-rc1 2014-01-20 16:05:23 -08:00
pci Revert "PCI: Remove from bus_list and release resources in pci_release_dev()" 2014-02-01 10:24:31 -08:00
pcmcia PCI changes for the v3.14 merge window: 2014-01-22 16:39:28 -08:00
phy Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-01-25 11:17:34 -08:00
pinctrl ARM: SoC DT updates for 3.14 2014-01-23 18:45:38 -08:00
platform platform/chrome: Cleanups and improvements 2014-01-29 20:06:01 -08:00
pnp Merge branch 'pnp' 2014-01-12 23:48:18 +01:00
power Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-01-25 11:17:34 -08:00
powercap
pps
ps3
ptp ptp_pch: Add dependency on HAS_IOMEM 2014-01-15 14:51:22 -08:00
pwm pwm: Changes for v3.14-rc1 2014-01-27 08:15:51 -08:00
rapidio
regulator regulator: Updates for v3.14 2014-01-25 13:19:10 -08:00
remoteproc
reset
rpmsg
rtc Merge branch 'akpm' (incoming from Andrew) 2014-01-23 19:11:50 -08:00
s390 Second batch of KVM updates. Some minor x86 fixes, 2014-01-31 08:37:32 -08:00
sbus sparc: delete non-required instances of include <linux/init.h> 2014-01-28 23:38:23 -08:00
scsi Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2014-01-31 15:31:23 -08:00
sfi
sh
sn
spi Merge remote-tracking branch 'agust/next' into next 2014-01-29 16:53:55 +11:00
ssb Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2014-01-30 17:20:32 -08:00
staging Staging wireless driver for 3.14-rc1 2014-02-01 10:29:59 -08:00
target Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2014-01-31 15:31:23 -08:00
tc
thermal Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux 2014-01-24 17:13:49 -08:00
tty Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2014-01-30 17:20:32 -08:00
uio
usb Merge remote-tracking branch 'agust/next' into next 2014-01-29 16:53:55 +11:00
uwb
vfio Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc 2014-01-27 21:11:26 -08:00
vhost Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2014-01-31 15:31:23 -08:00
video parisc/sti_console: prefer Linux fonts over built-in ROM fonts 2014-02-02 20:56:47 +01:00
virt
virtio A few simple fixes. Quiet cycle. 2014-01-22 22:24:35 -08:00
vlynq drivers/vlynq/vlynq.c: fix another resource size off by 1 error 2014-01-23 16:36:55 -08:00
vme
w1 drivers/w1/masters/w1-gpio.c: add strong pullup emulation 2014-01-23 16:37:04 -08:00
watchdog watchdog: w83627hf_wdt: Reset watchdog trigger during initialization 2014-01-28 21:35:40 +01:00
xen Bug-fixes: 2014-01-31 08:38:18 -08:00
zorro
Kconfig
Makefile