aboutsummaryrefslogtreecommitdiff
path: root/kernel/time/hrtimer.c
diff options
context:
space:
mode:
authorRafael J. Wysocki2018-04-07 19:11:55 +0200
committerRafael J. Wysocki2018-04-09 11:54:57 +0200
commit7d2f6abb402ae38ec4bb7beabb3980bb834b1e0d (patch)
tree14e65a4146f15cbea4369ef682058d21388f06a5 /kernel/time/hrtimer.c
parentff7de6203131e3d60cda60aeda12c69373ca5d43 (diff)
time: hrtimer: Use timerqueue_iterate_next() to get to the next timer
Use timerqueue_iterate_next() to get to the next timer in __hrtimer_next_event_base() without browsing the timerqueue details diredctly. No intentional changes in functionality. Suggested-by: Frederic Weisbecker <frederic@kernel.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'kernel/time/hrtimer.c')
-rw-r--r--kernel/time/hrtimer.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/kernel/time/hrtimer.c b/kernel/time/hrtimer.c
index 6d387dbd7304..14e858753d76 100644
--- a/kernel/time/hrtimer.c
+++ b/kernel/time/hrtimer.c
@@ -505,9 +505,7 @@ static ktime_t __hrtimer_next_event_base(struct hrtimer_cpu_base *cpu_base,
timer = container_of(next, struct hrtimer, node);
if (timer == exclude) {
/* Get to the next timer in the queue. */
- struct rb_node *rbn = rb_next(&next->node);
-
- next = rb_entry_safe(rbn, struct timerqueue_node, node);
+ next = timerqueue_iterate_next(next);
if (!next)
continue;