aboutsummaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/hrtimer.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c
index a6195617a..7832f70f4 100644
--- a/kernel/hrtimer.c
+++ b/kernel/hrtimer.c
@@ -241,10 +241,12 @@ again:
raw_spin_unlock(&base->cpu_base->lock);
raw_spin_lock(&new_base->cpu_base->lock);
+ this_cpu = smp_processor_id();
+
if (cpu != this_cpu && hrtimer_check_target(timer, new_base)) {
- cpu = this_cpu;
raw_spin_unlock(&new_base->cpu_base->lock);
raw_spin_lock(&base->cpu_base->lock);
+ cpu = smp_processor_id();
timer->base = base;
goto again;
}