mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 03:40:35 +09:00
ANDROID: thermal: Add vendor hook to check power range
For SoC's skin temperature, we have to use more stringent temperature
control to make IPA can monitor and mitigate temperature control earlier
and faster, so add it to meet platform thermal requirement.
Bug: 211564753
Signed-off-by: Jeson Gao <jeson.gao@unisoc.com>
Signed-off-by: Di Shen <di.shen@unisoc.com>
Change-Id: Iaef87287eef93d6fdbc3c58c93f70c1525e38296
(cherry picked from commit 6709f52325)
This commit is contained in:
@@ -262,3 +262,4 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_rwsem_init);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_rwsem_wake);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_rwsem_write_finished);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_alter_rwsem_list_add);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_thermal_power_cap);
|
||||
|
||||
@@ -470,6 +470,7 @@ static int allocate_power(struct thermal_zone_device *tz,
|
||||
}
|
||||
|
||||
power_range = pid_controller(tz, control_temp, max_allocatable_power);
|
||||
trace_android_vh_thermal_power_cap(&power_range);
|
||||
|
||||
divvy_up_power(weighted_req_power, max_power, num_actors,
|
||||
total_weighted_req_power, power_range, granted_power,
|
||||
|
||||
@@ -23,6 +23,9 @@ DECLARE_HOOK(android_vh_enable_thermal_power_throttle,
|
||||
TP_PROTO(int *enable),
|
||||
TP_ARGS(enable));
|
||||
|
||||
DECLARE_HOOK(android_vh_thermal_power_cap,
|
||||
TP_PROTO(u32 *power_range),
|
||||
TP_ARGS(power_range));
|
||||
#endif /* _TRACE_HOOK_THERMAL_H */
|
||||
/* This part must be outside protection */
|
||||
#include <trace/define_trace.h>
|
||||
|
||||
Reference in New Issue
Block a user