When vendor hooks are added to a file that previously didn't have any vendor hooks, we end up indirectly including linux/tracepoint.h. This causes some data types that used to be opaque (forward declared) to the code to become visible to the code. Modversions correctly catches this change in visibility, but we don't really care about the data types made visible when linux/tracepoint.h is included. So, hide this from modversions in the central vendor_hooks.h file instead of having to fix this on a case by case basis. This change itself will cause a one time CRC breakage/churn because it's fixing the existing vendor hook headers, but should reduce unnecessary CRC churns in the future. To avoid future pointless CRC churn, vendor hook header files that include vendor_hooks.h should not include linux/tracepoint.h directly. Bug: 227513263 Bug: 226140073 Signed-off-by: Saravana Kannan <saravanak@google.com> Change-Id: Ia88e6af11dd94fe475c464eb30a6e5e1e24c938b
44 lines
1.4 KiB
C
44 lines
1.4 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#undef TRACE_SYSTEM
|
|
#define TRACE_SYSTEM cpufreq
|
|
|
|
#define TRACE_INCLUDE_PATH trace/hooks
|
|
|
|
#if !defined(_TRACE_HOOK_CPUFREQ_H) || defined(TRACE_HEADER_MULTI_READ)
|
|
#define _TRACE_HOOK_CPUFREQ_H
|
|
|
|
#include <linux/cpufreq.h>
|
|
#include <trace/hooks/vendor_hooks.h>
|
|
|
|
DECLARE_RESTRICTED_HOOK(android_rvh_show_max_freq,
|
|
TP_PROTO(struct cpufreq_policy *policy, unsigned int *max_freq),
|
|
TP_ARGS(policy, max_freq), 1);
|
|
|
|
DECLARE_HOOK(android_vh_freq_table_limits,
|
|
TP_PROTO(struct cpufreq_policy *policy, unsigned int min_freq,
|
|
unsigned int max_freq),
|
|
TP_ARGS(policy, min_freq, max_freq));
|
|
|
|
DECLARE_RESTRICTED_HOOK(android_rvh_cpufreq_transition,
|
|
TP_PROTO(struct cpufreq_policy *policy),
|
|
TP_ARGS(policy), 1);
|
|
|
|
DECLARE_HOOK(android_vh_cpufreq_resolve_freq,
|
|
TP_PROTO(struct cpufreq_policy *policy, unsigned int *target_freq,
|
|
unsigned int old_target_freq),
|
|
TP_ARGS(policy, target_freq, old_target_freq));
|
|
|
|
DECLARE_HOOK(android_vh_cpufreq_fast_switch,
|
|
TP_PROTO(struct cpufreq_policy *policy, unsigned int *target_freq,
|
|
unsigned int old_target_freq),
|
|
TP_ARGS(policy, target_freq, old_target_freq));
|
|
|
|
DECLARE_HOOK(android_vh_cpufreq_target,
|
|
TP_PROTO(struct cpufreq_policy *policy, unsigned int *target_freq,
|
|
unsigned int old_target_freq),
|
|
TP_ARGS(policy, target_freq, old_target_freq));
|
|
|
|
#endif /* _TRACE_HOOK_CPUFREQ_H */
|
|
/* This part must be outside protection */
|
|
#include <trace/define_trace.h>
|