Re: [RFC v2 3/7] Improve the tracking of active utilisation
From: luca abeni
Date: Tue Apr 05 2016 - 13:17:52 EST
On Tue, 5 Apr 2016 16:48:03 +0200
Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
> On Fri, Apr 01, 2016 at 05:12:29PM +0200, Luca Abeni wrote:
> > + /*
> > + * We cannot use inactive_task_timer() to invoke sub_running_bw()
> > + * at the 0-lag time, because the task could have been migrated
> > + * while SCHED_OTHER in the meanwhile.
> > + */
> > + if (hrtimer_active(&p->dl.inactive_timer) &&
> > + !hrtimer_callback_running(&p->dl.inactive_timer))
> > sub_running_bw(&p->dl, &rq->dl);
>
> hrtimer_is_queued() ?
Uhm... I do not remember why I used this condition, but hrtimer_is_queued()
should be the right thing to be used, yes... I'll update the patch.
Thanks,
Luca