sm8450-common: Move to QTI health AIDL service

The health AIDL HAL service provides functionalities of charger,
therefore system charger at /system/bin/charger is deprecated.
On top of that, QTI health AIDL HAL service enables suspend by
default, the equivalent of setting ro.charger.enable_suspend
for legacy charger.

Change-Id: I59c23e7974cea1174b0161f31a535fa3afa1e5c9
This commit is contained in:
Bruno Martins 2023-11-13 13:48:00 +00:00 committed by Arian
parent b07068f0f8
commit 2d6f07b00c
6 changed files with 7 additions and 14 deletions

View file

@ -226,7 +226,7 @@ PRODUCT_COPY_FILES += \
# Health # Health
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
android.hardware.health@2.1-service android.hardware.health-service.qti
# HIDL # HIDL
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \

View file

@ -60,6 +60,9 @@ fi
function blob_fixup() { function blob_fixup() {
case "${1}" in case "${1}" in
vendor/etc/init/hw/init.mi_thermald.rc|vendor/etc/init/hw/init.qcom.usb.rc|vendor/etc/init/hw/init.qti.kernel.rc)
sed -i 's/on charger/on property:init.svc.vendor.charger=running/g' "${2}"
;;
vendor/etc/init/init.embmssl_server.rc) vendor/etc/init/init.embmssl_server.rc)
sed -i -n '/interface/!p' "${2}" sed -i -n '/interface/!p' "${2}"
;; ;;

View file

@ -1,6 +1,3 @@
# Charger
ro.charger.enable_suspend=1
# CNE # CNE
persist.vendor.cne.feature=1 persist.vendor.cne.feature=1

View file

@ -725,13 +725,6 @@ service profiler_daemon /system/bin/profiler_daemon
group root group root
disabled disabled
service charger /system/bin/charger
class charger
user system
group system graphics input
capabilities SYS_BOOT
seclabel u:r:charger:s0
service vendor.ssr_diag /system/vendor/bin/ssr_diag service vendor.ssr_diag /system/vendor/bin/ssr_diag
class late_start class late_start
user system user system
@ -810,7 +803,7 @@ service esepmdaemon /system/vendor/bin/esepmdaemon
user system user system
group nfc group nfc
on charger on property:init.svc.vendor.charger=running
setprop persist.sys.usb.config mass_storage setprop persist.sys.usb.config mass_storage
start qcom-post-boot start qcom-post-boot

View file

@ -139,7 +139,7 @@ on init && property:ro.boot.mode=charger
wait /sys/kernel/boot_adsp/boot wait /sys/kernel/boot_adsp/boot
write /sys/kernel/boot_adsp/boot 1 write /sys/kernel/boot_adsp/boot 1
on charger on property:init.svc.vendor.charger=running
start vendor.power_off_alarm start vendor.power_off_alarm
setprop sys.usb.controller a600000.dwc3 setprop sys.usb.controller a600000.dwc3
wait /sys/class/udc/${sys.usb.controller} wait /sys/class/udc/${sys.usb.controller}

View file

@ -155,7 +155,7 @@ on property:sys.boot_completed=1
# Set thermal mode to mgame # Set thermal mode to mgame
write /sys/devices/virtual/thermal/thermal_message/sconfig 20 write /sys/devices/virtual/thermal/thermal_message/sconfig 20
on charger on property:init.svc.vendor.charger=running
chown system system /sys/class/backlight/panel0-backlight/brightness chown system system /sys/class/backlight/panel0-backlight/brightness
chown system system /sys/class/backlight/panel1-backlight/brightness chown system system /sys/class/backlight/panel1-backlight/brightness