lkml.org 
[lkml]   [2014]   [Apr]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 07/38] tick-oneshot: drop local_irq_save/restore from tick_switch_to_oneshot()
Date
tick_switch_to_oneshot() is just reading value of
__this_cpu_read(tick_cpu_device.mode) and doesn't need to disable local
interrupts for that. Drop local_irq_save/restore calls from this routine.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
kernel/time/tick-oneshot.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/kernel/time/tick-oneshot.c b/kernel/time/tick-oneshot.c
index 6a531ec..39492f1 100644
--- a/kernel/time/tick-oneshot.c
+++ b/kernel/time/tick-oneshot.c
@@ -92,14 +92,7 @@ int tick_switch_to_oneshot(void (*handler)(struct clock_event_device *))
*/
int tick_oneshot_mode_active(void)
{
- unsigned long flags;
- int ret;
-
- local_irq_save(flags);
- ret = tick_get_cpu_device()->mode == TICKDEV_MODE_ONESHOT;
- local_irq_restore(flags);
-
- return ret;
+ return tick_get_cpu_device()->mode == TICKDEV_MODE_ONESHOT;
}

#ifdef CONFIG_HIGH_RES_TIMERS
--
1.7.12.rc2.18.g61b472e


\
 
 \ /
  Last update: 2014-04-18 19:41    [W:0.299 / U:14.276 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site