Skip to content

Commit

Permalink
hrtimer: Use accesor functions instead of direct access
Browse files Browse the repository at this point in the history
__hrtimer_hres_active() is now available unconditionally, so replace open
coded direct accesses to hrtimer_cpu_base.hres_active.

No functional change.

Signed-off-by: Anna-Maria Gleixner <[email protected]>
Cc: Christoph Hellwig <[email protected]>
Cc: John Stultz <[email protected]>
Cc: Linus Torvalds <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: [email protected]
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
  • Loading branch information
anna-marialx authored and Ingo Molnar committed Jan 16, 2018
1 parent 28bfd18 commit 851cff8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kernel/time/hrtimer.c
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ hrtimer_force_reprogram(struct hrtimer_cpu_base *cpu_base, int skip_equal)
{
ktime_t expires_next;

if (!cpu_base->hres_active)
if (!__hrtimer_hres_active(cpu_base))
return;

expires_next = __hrtimer_get_next_event(cpu_base);
Expand Down Expand Up @@ -673,7 +673,7 @@ static void retrigger_next_event(void *arg)
{
struct hrtimer_cpu_base *base = this_cpu_ptr(&hrtimer_bases);

if (!base->hres_active)
if (!__hrtimer_hres_active(base))
return;

raw_spin_lock(&base->lock);
Expand Down

0 comments on commit 851cff8

Please sign in to comment.