mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 18:41:58 +09:00
ANDROID: vendor_hooks: Add hooks for account process tick
Add a hook in account_process_tick, which help us to get information about the high load task and the cpu they running on. Bug: 183260319 Change-Id: I54162ce3c65bd69e08d2d4747e4d4883efe4c442 Signed-off-by: Liujie Xie <xieliujie@oppo.com>
This commit is contained in:
committed by
Treehugger Robot
parent
32ff609a32
commit
c92b19e8e4
@@ -351,6 +351,10 @@ DECLARE_HOOK(android_vh_account_process_tick_gran,
|
||||
TP_PROTO(int user_tick, int *ticks),
|
||||
TP_ARGS(user_tick, ticks));
|
||||
|
||||
DECLARE_HOOK(android_vh_account_task_time,
|
||||
TP_PROTO(struct task_struct *p, struct rq *rq, int user_tick, int ticks),
|
||||
TP_ARGS(p, rq, user_tick, ticks));
|
||||
|
||||
/* macro versions of hooks are no longer required */
|
||||
|
||||
#endif /* _TRACE_HOOK_SCHED_H */
|
||||
|
||||
@@ -507,6 +507,7 @@ void account_process_tick(struct task_struct *p, int user_tick)
|
||||
|
||||
if (vtime_accounting_enabled_this_cpu())
|
||||
return;
|
||||
trace_android_vh_account_task_time(p, this_rq(), user_tick, ticks);
|
||||
|
||||
if (sched_clock_irqtime) {
|
||||
irqtime_account_process_tick(p, user_tick, ticks);
|
||||
|
||||
@@ -90,3 +90,4 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_map_util_freq);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_set_cpus_allowed_comm);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_sched_setaffinity_early);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_account_process_tick_gran);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_account_task_time);
|
||||
|
||||
Reference in New Issue
Block a user