diff options
-rw-r--r-- | kernel/sched/fair.c | 5 | ||||
-rw-r--r-- | kernel/sched/rt.c | 10 | ||||
-rw-r--r-- | kernel/sched/sched.h | 12 |
3 files changed, 11 insertions, 16 deletions
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 5e157f157d85..43232b8bacde 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c | |||
@@ -6732,10 +6732,7 @@ static int idle_balance(struct rq *this_rq) | |||
6732 | 6732 | ||
6733 | out: | 6733 | out: |
6734 | /* Is there a task of a high priority class? */ | 6734 | /* Is there a task of a high priority class? */ |
6735 | if (this_rq->nr_running != this_rq->cfs.h_nr_running && | 6735 | if (this_rq->nr_running != this_rq->cfs.h_nr_running) |
6736 | ((this_rq->stop && this_rq->stop->on_rq) || | ||
6737 | this_rq->dl.dl_nr_running || | ||
6738 | (this_rq->rt.rt_nr_running && !rt_rq_throttled(&this_rq->rt)))) | ||
6739 | pulled_task = -1; | 6736 | pulled_task = -1; |
6740 | 6737 | ||
6741 | if (pulled_task) { | 6738 | if (pulled_task) { |
diff --git a/kernel/sched/rt.c b/kernel/sched/rt.c index 2add019ddbd0..7795e292f4c9 100644 --- a/kernel/sched/rt.c +++ b/kernel/sched/rt.c | |||
@@ -493,6 +493,11 @@ static void sched_rt_rq_dequeue(struct rt_rq *rt_rq) | |||
493 | dequeue_rt_entity(rt_se); | 493 | dequeue_rt_entity(rt_se); |
494 | } | 494 | } |
495 | 495 | ||
496 | static inline int rt_rq_throttled(struct rt_rq *rt_rq) | ||
497 | { | ||
498 | return rt_rq->rt_throttled && !rt_rq->rt_nr_boosted; | ||
499 | } | ||
500 | |||
496 | static int rt_se_boosted(struct sched_rt_entity *rt_se) | 501 | static int rt_se_boosted(struct sched_rt_entity *rt_se) |
497 | { | 502 | { |
498 | struct rt_rq *rt_rq = group_rt_rq(rt_se); | 503 | struct rt_rq *rt_rq = group_rt_rq(rt_se); |
@@ -569,6 +574,11 @@ static inline void sched_rt_rq_dequeue(struct rt_rq *rt_rq) | |||
569 | dequeue_top_rt_rq(rt_rq); | 574 | dequeue_top_rt_rq(rt_rq); |
570 | } | 575 | } |
571 | 576 | ||
577 | static inline int rt_rq_throttled(struct rt_rq *rt_rq) | ||
578 | { | ||
579 | return rt_rq->rt_throttled; | ||
580 | } | ||
581 | |||
572 | static inline const struct cpumask *sched_rt_period_mask(void) | 582 | static inline const struct cpumask *sched_rt_period_mask(void) |
573 | { | 583 | { |
574 | return cpu_online_mask; | 584 | return cpu_online_mask; |
diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h index c8d9ee418ca7..b2cbe81308af 100644 --- a/kernel/sched/sched.h +++ b/kernel/sched/sched.h | |||
@@ -425,18 +425,6 @@ struct rt_rq { | |||
425 | #endif | 425 | #endif |
426 | }; | 426 | }; |
427 | 427 | ||
428 | #ifdef CONFIG_RT_GROUP_SCHED | ||
429 | static inline int rt_rq_throttled(struct rt_rq *rt_rq) | ||
430 | { | ||
431 | return rt_rq->rt_throttled && !rt_rq->rt_nr_boosted; | ||
432 | } | ||
433 | #else | ||
434 | static inline int rt_rq_throttled(struct rt_rq *rt_rq) | ||
435 | { | ||
436 | return rt_rq->rt_throttled; | ||
437 | } | ||
438 | #endif | ||
439 | |||
440 | /* Deadline class' related fields in a runqueue */ | 428 | /* Deadline class' related fields in a runqueue */ |
441 | struct dl_rq { | 429 | struct dl_rq { |
442 | /* runqueue is an rbtree, ordered by deadline */ | 430 | /* runqueue is an rbtree, ordered by deadline */ |