deadline.c (dfcb245e28481256a10a9133441baf2a93d26642) deadline.c (9ebc6053814d37b9de8cc291fba28f30a729c929)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Deadline Scheduling Class (SCHED_DEADLINE)
4 *
5 * Earliest Deadline First (EDF) + Constant Bandwidth Server (CBS).
6 *
7 * Tasks that periodically executes their instances for less than their
8 * runtime won't miss any of their deadlines.

--- 2028 unchanged lines hidden (view full) ---

2037 if (!rq->dl.overloaded)
2038 return 0;
2039
2040 next_task = pick_next_pushable_dl_task(rq);
2041 if (!next_task)
2042 return 0;
2043
2044retry:
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Deadline Scheduling Class (SCHED_DEADLINE)
4 *
5 * Earliest Deadline First (EDF) + Constant Bandwidth Server (CBS).
6 *
7 * Tasks that periodically executes their instances for less than their
8 * runtime won't miss any of their deadlines.

--- 2028 unchanged lines hidden (view full) ---

2037 if (!rq->dl.overloaded)
2038 return 0;
2039
2040 next_task = pick_next_pushable_dl_task(rq);
2041 if (!next_task)
2042 return 0;
2043
2044retry:
2045 if (unlikely(next_task == rq->curr)) {
2046 WARN_ON(1);
2045 if (WARN_ON(next_task == rq->curr))
2047 return 0;
2046 return 0;
2048 }
2049
2050 /*
2051 * If next_task preempts rq->curr, and rq->curr
2052 * can move away, it makes sense to just reschedule
2053 * without going further in pushing next_task.
2054 */
2055 if (dl_task(rq->curr) &&
2056 dl_time_before(next_task->dl.deadline, rq->curr->dl.deadline) &&

--- 702 unchanged lines hidden ---
2047
2048 /*
2049 * If next_task preempts rq->curr, and rq->curr
2050 * can move away, it makes sense to just reschedule
2051 * without going further in pushing next_task.
2052 */
2053 if (dl_task(rq->curr) &&
2054 dl_time_before(next_task->dl.deadline, rq->curr->dl.deadline) &&

--- 702 unchanged lines hidden ---