Skip to content

Commit 12a7764

Browse files
committed
sched/alt: Remove psi support
There are issues(#70, torvalds#72, torvalds#79) with psi support. Removing the support of psi as it doesn't bring much gain.
1 parent 4b2d604 commit 12a7764

File tree

3 files changed

+1
-9
lines changed

3 files changed

+1
-9
lines changed

init/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -670,6 +670,7 @@ config TASK_IO_ACCOUNTING
670670

671671
config PSI
672672
bool "Pressure stall information tracking"
673+
depends on !SCHED_ALT
673674
select KERNFS
674675
help
675676
Collect metrics that indicate how overcommitted the CPU, memory,

kernel/sched/alt_core.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,6 @@ static void update_rq_clock_task(struct rq *rq, s64 delta)
588588

589589
rq->prev_irq_time += irq_delta;
590590
delta -= irq_delta;
591-
psi_account_irqtime(rq->curr, irq_delta);
592591
#endif
593592
#ifdef CONFIG_PARAVIRT_TIME_ACCOUNTING
594593
if (static_key_false((&paravirt_steal_rq_enabled))) {
@@ -769,7 +768,6 @@ unsigned long get_wchan(struct task_struct *p)
769768
*/
770769
#define __SCHED_DEQUEUE_TASK(p, rq, flags, func) \
771770
sched_info_dequeue(rq, p); \
772-
psi_dequeue(p, flags & DEQUEUE_SLEEP); \
773771
\
774772
list_del(&p->sq_node); \
775773
if (list_empty(&rq->queue.heads[p->sq_idx])) { \
@@ -779,7 +777,6 @@ unsigned long get_wchan(struct task_struct *p)
779777

780778
#define __SCHED_ENQUEUE_TASK(p, rq, flags) \
781779
sched_info_enqueue(rq, p); \
782-
psi_enqueue(p, flags & ENQUEUE_WAKEUP); \
783780
\
784781
p->sq_idx = task_sched_prio_idx(p, rq); \
785782
list_add_tail(&p->sq_node, &rq->queue.heads[p->sq_idx]); \
@@ -2954,7 +2951,6 @@ static int try_to_wake_up(struct task_struct *p, unsigned int state,
29542951
}
29552952

29562953
wake_flags |= WF_MIGRATED;
2957-
psi_ttwu_dequeue(p);
29582954
set_task_cpu(p, cpu);
29592955
}
29602956
#else
@@ -4828,8 +4824,6 @@ static void __sched notrace __schedule(unsigned int sched_mode)
48284824
*/
48294825
++*switch_count;
48304826

4831-
psi_sched_switch(prev, next, !task_on_rq_queued(prev));
4832-
48334827
trace_sched_switch(sched_mode & SM_MASK_PREEMPT, prev, next, prev_state);
48344828

48354829
/* Also unlocks the rq: */
@@ -7689,8 +7683,6 @@ void __init sched_init(void)
76897683
sched_init_topology_cpumask_early();
76907684
#endif /* SMP */
76917685

7692-
psi_init();
7693-
76947686
preempt_dynamic_init();
76957687
}
76967688

kernel/sched/alt_sched.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
#include <linux/context_tracking.h>
55
#include <linux/profile.h>
6-
#include <linux/psi.h>
76
#include <linux/stop_machine.h>
87
#include <linux/syscalls.h>
98
#include <linux/tick.h>

0 commit comments

Comments
 (0)