• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #undef TRACE_SYSTEM
3 #define TRACE_SYSTEM cpufreq
4 
5 #define TRACE_INCLUDE_PATH trace/hooks
6 
7 #if !defined(_TRACE_HOOK_CPUFREQ_H) || defined(TRACE_HEADER_MULTI_READ)
8 #define _TRACE_HOOK_CPUFREQ_H
9 
10 #include <trace/hooks/vendor_hooks.h>
11 
12 struct cpufreq_policy;
13 
14 DECLARE_RESTRICTED_HOOK(android_rvh_show_max_freq,
15 	TP_PROTO(struct cpufreq_policy *policy, unsigned int *max_freq),
16 	TP_ARGS(policy, max_freq), 1);
17 
18 DECLARE_HOOK(android_vh_freq_table_limits,
19 	TP_PROTO(struct cpufreq_policy *policy, unsigned int min_freq,
20 		 unsigned int max_freq),
21 	TP_ARGS(policy, min_freq, max_freq));
22 
23 DECLARE_HOOK(android_vh_cpufreq_acct_update_power,
24 	TP_PROTO(u64 cputime, struct task_struct *p, unsigned int state),
25 	TP_ARGS(cputime, p, state));
26 
27 DECLARE_RESTRICTED_HOOK(android_rvh_cpufreq_transition,
28 	TP_PROTO(struct cpufreq_policy *policy),
29 	TP_ARGS(policy), 1);
30 
31 DECLARE_HOOK(android_vh_cpufreq_resolve_freq,
32 	TP_PROTO(struct cpufreq_policy *policy, unsigned int *target_freq,
33 		unsigned int old_target_freq),
34 	TP_ARGS(policy, target_freq, old_target_freq));
35 
36 DECLARE_HOOK(android_vh_cpufreq_fast_switch,
37 	TP_PROTO(struct cpufreq_policy *policy, unsigned int *target_freq,
38 		unsigned int old_target_freq),
39 	TP_ARGS(policy, target_freq, old_target_freq));
40 
41 DECLARE_HOOK(android_vh_cpufreq_target,
42 	TP_PROTO(struct cpufreq_policy *policy, unsigned int *target_freq,
43 		unsigned int old_target_freq),
44 	TP_ARGS(policy, target_freq, old_target_freq));
45 
46 #endif /* _TRACE_HOOK_CPUFREQ_H */
47 /* This part must be outside protection */
48 #include <trace/define_trace.h>
49