Re: [PATCH 2/2] sched/deadline: Throttle a constrained deadline task activated after the deadline

From: Daniel Bristot de Oliveira
Date: Mon Feb 13 2017 - 11:22:01 EST


On 02/13/2017 04:46 PM, Daniel Bristot de Oliveira wrote:
> On 02/13/2017 04:33 PM, Steven Rostedt wrote:
>>> +static inline bool dl_is_constrained(struct sched_dl_entity *dl_se)
>>> +{
>>> + return dl_se->dl_runtime < dl_se->dl_period;
>>> +}
>>> +
>> Is it ever appropriate for a dl task to have runtime == period? What
>> purpose would that serve? Just run the task as FIFO higher than
>> everything else.
>>
>> Or was this suppose to be dl_deadline < dl_period?
> Oooooops, my bad :-(, this was supposed to be dl_deadline < dl_period.

As

+ if (dl_time_before(dl_se->deadline, rq_clock(rq)) &&
+ dl_time_before(rq_clock(rq), dl_next_period(dl_se))) {


is never true for implicit deadline tasks, the problem was not causing
further logical issues (apart from being conceptually obviously totally
wrong, and causes the check to be called without the need to... me--).

-- Daniel