Please refer to http://comments.gmane.org/gmane.linux.kernel/
1891417, the
last two mails on this discussion.
The non_hz_full is important for RT, so take it back temporarily.
Unluckily I didn't find the corresponding reverting patch on the RT tree.
Upstream status: pending
Change-Id: I2748a8f9b7a98ef2185a1da60089984432393eff
Signed-off-by: Yunhong Jiang <yunhong.jiang@linux.intel.com>
* the base lock to check when the next timer is pending and so
* we assume the next jiffy.
*/
* the base lock to check when the next timer is pending and so
* we assume the next jiffy.
*/
- return basem + TICK_NSEC;
-#endif
+ if (!spin_do_trylock(&base->lock))
+ return basem + TICK_NSEC;
+#else
if (base->active_timers) {
if (time_before_eq(base->next_timer, base->timer_jiffies))
base->next_timer = __next_timer_interrupt(base);
if (base->active_timers) {
if (time_before_eq(base->next_timer, base->timer_jiffies))
base->next_timer = __next_timer_interrupt(base);
else
expires = basem + (nextevt - basej) * TICK_NSEC;
}
else
expires = basem + (nextevt - basej) * TICK_NSEC;
}
+#ifdef CONFIG_PREEMPT_RT_FULL
+ rt_spin_unlock(&base->lock);
+#else
spin_unlock(&base->lock);
spin_unlock(&base->lock);
return cmp_next_hrtimer_event(basem, expires);
}
return cmp_next_hrtimer_event(basem, expires);
}