aboutsummaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/sched.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/kernel/sched.c b/kernel/sched.c
index f04add905bd..fdd26fffaa2 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -2915,6 +2915,9 @@ static inline int wake_priority_sleeper(struct rq *rq)
int ret = 0;
#ifdef CONFIG_SCHED_SMT
+ if (!rq->nr_running)
+ return 0;
+
spin_lock(&rq->lock);
/*
* If an SMT sibling task has been put to sleep for priority