thermal: Dynamically decide thermal config to use

Add service which will device thermal config on basis of following
conditions:

- No display panel / proto, use thermal_info_config_proto

Bug: 315096213
Test: Build and verify on all device variations
Change-Id: Ic1f652dcf38888150200bb80b35aad740058e85f
This commit is contained in:
sashwinbalaji 2023-12-06 16:40:22 +08:00
parent 242d7789a3
commit edb8b488e5
8 changed files with 580 additions and 887 deletions

View file

@ -47,11 +47,18 @@ on init && property:ro.bootmode=factory
write /sys/devices/platform/hall_sensor/enable 0
# Thermal
on late-init && property:ro.boot.hardware.revision=PROTO1.0
setprop vendor.thermal.config "thermal_info_config_proto.json"
service init_thermal_config /vendor/bin/init_thermal_config
class main
user root
group root system
disabled
oneshot
on late-init && property:ro.boot.hardware.revision=PROTO1.1
setprop vendor.thermal.config "thermal_info_config_proto.json"
on late-init
start init_thermal_config
on property:vendor.thermal.config=thermal_info_config_charge
start init_thermal_config
on property:vendor.thermal.link_ready=1
chown system system /dev/thermal/tz-by-name/charger_therm/trip_point_0_temp