ANDROID: sched: Add trace hook for DL server

Create a trace hook when the DL server is activated.
This allows vendors to debug RT/Fair contention issues
by dumping the following information:

1.The task served by the DL server
2.The status of the DL server

Bug: 436885337

Change-Id: I2157bd22b7d7c80d7ec1eeeba3ec6fb88efa4abd
Signed-off-by: kuyo chang <kuyo.chang@mediatek.com>
Signed-off-by: kuyo chang <kuyo.chang@mediatek.corp-partner.google.com>
This commit is contained in:
kuyo chang
2025-08-08 11:30:31 +08:00
committed by Treehugger Robot
parent e76cff4952
commit 47cca68200
3 changed files with 7 additions and 0 deletions
+5
View File
@@ -531,6 +531,11 @@ DECLARE_RESTRICTED_HOOK(android_rvh_util_fits_cpu,
int cpu, bool *fits, bool *done),
TP_ARGS(util, uclamp_min, uclamp_max, cpu, fits, done), 1);
struct sched_dl_entity;
DECLARE_HOOK(android_vh_dump_dl_server,
TP_PROTO(struct sched_dl_entity *dl_se, struct task_struct *p),
TP_ARGS(dl_se, p));
/* macro versions of hooks are no longer required */
#endif /* _TRACE_HOOK_SCHED_H */
+1
View File
@@ -2462,6 +2462,7 @@ again:
goto again;
}
rq->dl_server = dl_se;
trace_android_vh_dump_dl_server(dl_se, p);
} else {
p = dl_task_of(dl_se);
}
+1
View File
@@ -136,3 +136,4 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_uclamp_validate);
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_util_fits_cpu);
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_before_pick_task_fair);
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_balance_fair);
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_dump_dl_server);