summaryrefslogtreecommitdiff
path: root/sys-kernel/pf-sources/files/pf-sources-5.17.2-sched-uclamp-fix-functions.patch
blob: 24404669add65e7a141145574d90ab5d7777293f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
From 170a1f1454a4453c0053f87723fd15634c863e05 Mon Sep 17 00:00:00 2001
From: Tor Vic <torvic9@mailbox.org>
Date: Thu, 7 Apr 2022 14:54:10 +0200
Subject: [PATCH] sched/alt: [Sync] sched/uclamp: Add dummy functions to
 sched_alt.h

Syncup of the following 5.17.2 commits:
  sched/uclamp: Fix iowait boost escaping uclamp restriction
  sched/sugov: Ignore 'busy' filter when rq is capped by uclamp_max

Link: https://gitlab.com/alfredchen/linux-prjc/-/issues/56
---
 kernel/sched/alt_sched.h | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/kernel/sched/alt_sched.h b/kernel/sched/alt_sched.h
index f2b9e686d6a6..55c2a4c0cb84 100644
--- a/kernel/sched/alt_sched.h
+++ b/kernel/sched/alt_sched.h
@@ -654,6 +654,20 @@ static inline int sched_numa_find_closest(const struct cpumask *cpus, int cpu)
 }
 #endif
 
+static inline
+unsigned long uclamp_rq_util_with(struct rq *rq, unsigned long boost,
+				  struct task_struct *p)
+{
+	return boost;
+}
+
+static inline bool uclamp_rq_is_capped(struct rq *rq) { return false; }
+
+static inline bool uclamp_is_used(void)
+{
+	return false;
+}
+
 extern void swake_up_all_locked(struct swait_queue_head *q);
 extern void __prepare_to_swait(struct swait_queue_head *q, struct swait_queue *wait);
 
-- 
GitLab