
Add vendor hook to thermal to allow vendor to selectively disable thermal cooling device stats feature based on requirement. It helps vendor to optimize memory footprint due to this feature especially for low memory devices. Bug: 218825214 Change-Id: I2ec72505f03575e09229c54765584614b16a3904 Signed-off-by: Manaf Meethalavalappu Pallikunhi <quic_manafm@quicinc.com> (cherry picked from commit f6e47fd00f24d5e814d316b03974e970dd87879e)
36 lines
1.0 KiB
C
36 lines
1.0 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#undef TRACE_SYSTEM
|
|
#define TRACE_SYSTEM thermal
|
|
|
|
#define TRACE_INCLUDE_PATH trace/hooks
|
|
|
|
#if !defined(_TRACE_HOOK_THERMAL_H) || defined(TRACE_HEADER_MULTI_READ)
|
|
#define _TRACE_HOOK_THERMAL_H
|
|
|
|
#include <linux/tracepoint.h>
|
|
#include <trace/hooks/vendor_hooks.h>
|
|
|
|
#ifdef __GENKSYMS__
|
|
struct thermal_zone_device;
|
|
#else
|
|
/* struct thermal_zone_device */
|
|
#include <linux/thermal.h>
|
|
#endif /* __GENKSYMS__ */
|
|
DECLARE_HOOK(android_vh_enable_thermal_genl_check,
|
|
TP_PROTO(int event, int tz_id, int *enable_thermal_genl),
|
|
TP_ARGS(event, tz_id, enable_thermal_genl));
|
|
|
|
DECLARE_HOOK(android_vh_thermal_pm_notify_suspend,
|
|
TP_PROTO(struct thermal_zone_device *tz, int *irq_wakeable),
|
|
TP_ARGS(tz, irq_wakeable));
|
|
|
|
struct thermal_cooling_device;
|
|
DECLARE_HOOK(android_vh_disable_thermal_cooling_stats,
|
|
TP_PROTO(struct thermal_cooling_device *cdev, bool *disable_stats),
|
|
TP_ARGS(cdev, disable_stats));
|
|
|
|
#endif /* _TRACE_HOOK_THERMAL_H */
|
|
/* This part must be outside protection */
|
|
#include <trace/define_trace.h>
|
|
|