Skip to contentSkip to conversation

sched/deadline: Fix replenish_dl_new_period dl_server condition

PATCH Applied Juri Lelli 2 participants 2 messages Nov 27, 2024 – Dec 2, 2024

Subsystems (2)
lore
Share & tools
lore

Juri Lelli

author maintainer
#0 lore raw

PATCH 1/1 sched/deadline: Fix replenish_dl_new_period dl_server condition

The condition in replenish_dl_new_period() that checks if a reservation (dl_server) is deferred and is not handling a starvation case is obviously wrong.

Fix it.

Cc Ingo Molnar <[email protected]>
Cc Peter Zijlstra <[email protected]>
Cc Vincent Guittot <[email protected]>
Cc Dietmar Eggemann <[email protected]>
Cc Steven Rostedt <[email protected]>
Cc Ben Segall <[email protected]>
Cc Mel Gorman <[email protected]>
Cc Valentin Schneider <[email protected]>
Fixes a110a81c52a9 ("sched/deadline: Deferrable dl server")
---
 kernel/sched/deadline.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/sched/deadline.c +1 -1
index d9d5a702f1a6..206691d35b7d 100644
@@ -781,7 +781,7 @@ static inline void replenish_dl_new_period(struct sched_dl_entity *dl_se,
 	 * If it is a deferred reservation, and the server
 	 * is not handling an starvation case, defer it.
 	 */
-	if (dl_se->dl_defer & !dl_se->dl_defer_running) {
+	if (dl_se->dl_defer && !dl_se->dl_defer_running) {
 		dl_se->dl_throttled = 1;
 		dl_se->dl_defer_armed = 1;
 	}
Signature · 1 line
2.47.0
merge bot Applied
#1 lore raw
The following commit has been merged into the sched/core branch of tip:

The following commit has been merged into the sched/core branch of tip:

Commit-ID:     22368fe1f9bbf39db2b5b52859589883273e80ce
Gitweb:        https://git.kernel.org/tip/22368fe1f9bbf39db2b5b52859589883273e80ce
Author:        Juri Lelli <[email protected]>
AuthorDate:    Wed, 27 Nov 2024 07:37:40 +01:00
Committer:     Peter Zijlstra <[email protected]>
CommitterDate: Mon, 02 Dec 2024 12:01:27 +01:00

sched/deadline: Fix replenish_dl_new_period dl_server condition

The condition in replenish_dl_new_period() that checks if a reservation (dl_server) is deferred and is not handling a starvation case is obviously wrong.

Fix it.

---
 kernel/sched/deadline.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/sched/deadline.c +1 -1
index d9d5a70..206691d 100644
@@ -781,7 +781,7 @@ static inline void replenish_dl_new_period(struct sched_dl_entity *dl_se,
 	 * If it is a deferred reservation, and the server
 	 * is not handling an starvation case, defer it.
 	 */
-	if (dl_se->dl_defer & !dl_se->dl_defer_running) {
+	if (dl_se->dl_defer && !dl_se->dl_defer_running) {
 		dl_se->dl_throttled = 1;
 		dl_se->dl_defer_armed = 1;
 	}