diff options
author | Ingo Molnar <mingo@kernel.org> | 2015-07-31 10:23:35 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2015-07-31 10:23:35 +0200 |
commit | 5b929bd11df23922daf1be5d52731cc3900c1d79 (patch) | |
tree | 105fa5987b03c9f4e0260a9eb04dff7bb3d16839 /kernel/time/tick-common.c | |
parent | b2c51106c7581866c37ffc77c5d739f3d4b7cbc9 (diff) | |
parent | 37868fe113ff2ba814b3b4eb12df214df555f8dc (diff) | |
download | op-kernel-dev-5b929bd11df23922daf1be5d52731cc3900c1d79.zip op-kernel-dev-5b929bd11df23922daf1be5d52731cc3900c1d79.tar.gz |
Merge branch 'x86/urgent' into x86/asm, before applying dependent patches
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/time/tick-common.c')
-rw-r--r-- | kernel/time/tick-common.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/kernel/time/tick-common.c b/kernel/time/tick-common.c index 76446cb..f8bf475 100644 --- a/kernel/time/tick-common.c +++ b/kernel/time/tick-common.c @@ -343,6 +343,28 @@ out_bc: tick_install_broadcast_device(newdev); } +/** + * tick_broadcast_oneshot_control - Enter/exit broadcast oneshot mode + * @state: The target state (enter/exit) + * + * The system enters/leaves a state, where affected devices might stop + * Returns 0 on success, -EBUSY if the cpu is used to broadcast wakeups. + * + * Called with interrupts disabled, so clockevents_lock is not + * required here because the local clock event device cannot go away + * under us. + */ +int tick_broadcast_oneshot_control(enum tick_broadcast_state state) +{ + struct tick_device *td = this_cpu_ptr(&tick_cpu_device); + + if (!(td->evtdev->features & CLOCK_EVT_FEAT_C3STOP)) + return 0; + + return __tick_broadcast_oneshot_control(state); +} +EXPORT_SYMBOL_GPL(tick_broadcast_oneshot_control); + #ifdef CONFIG_HOTPLUG_CPU /* * Transfer the do_timer job away from a dying cpu. |