diff options
-rw-r--r-- | kernel/sched/rt.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/kernel/sched/rt.c b/kernel/sched/rt.c index 575da76a3874..613574c71a68 100644 --- a/kernel/sched/rt.c +++ b/kernel/sched/rt.c | |||
@@ -8,6 +8,8 @@ | |||
8 | #include <linux/slab.h> | 8 | #include <linux/slab.h> |
9 | #include <linux/irq_work.h> | 9 | #include <linux/irq_work.h> |
10 | 10 | ||
11 | #include <litmus/litmus.h> | ||
12 | |||
11 | int sched_rr_timeslice = RR_TIMESLICE; | 13 | int sched_rr_timeslice = RR_TIMESLICE; |
12 | 14 | ||
13 | static int do_sched_rt_period_timer(struct rt_bandwidth *rt_b, int overrun); | 15 | static int do_sched_rt_period_timer(struct rt_bandwidth *rt_b, int overrun); |
@@ -487,8 +489,9 @@ static void sched_rt_rq_enqueue(struct rt_rq *rt_rq) | |||
487 | enqueue_top_rt_rq(rt_rq); | 489 | enqueue_top_rt_rq(rt_rq); |
488 | else if (!on_rt_rq(rt_se)) | 490 | else if (!on_rt_rq(rt_se)) |
489 | enqueue_rt_entity(rt_se, false); | 491 | enqueue_rt_entity(rt_se, false); |
490 | 492 | if (rt_rq->highest_prio.curr < curr->prio | |
491 | if (rt_rq->highest_prio.curr < curr->prio) | 493 | /* Don't subject LITMUS^RT tasks to remote reschedules. */ |
494 | && !is_realtime(curr)) | ||
492 | resched_curr(rq); | 495 | resched_curr(rq); |
493 | } | 496 | } |
494 | } | 497 | } |
@@ -575,7 +578,7 @@ static inline void sched_rt_rq_enqueue(struct rt_rq *rt_rq) | |||
575 | { | 578 | { |
576 | struct rq *rq = rq_of_rt_rq(rt_rq); | 579 | struct rq *rq = rq_of_rt_rq(rt_rq); |
577 | 580 | ||
578 | if (!rt_rq->rt_nr_running) | 581 | if (!rt_rq->rt_nr_running || is_realtime(rq_of_rt_rq(rt_rq)->curr)) |
579 | return; | 582 | return; |
580 | 583 | ||
581 | enqueue_top_rt_rq(rt_rq); | 584 | enqueue_top_rt_rq(rt_rq); |