hardware_xiaomi/aidl/power-libperfmgr/android.hardware.power-service.xiaomi-libperfmgr.rc
Wei Wang 1fbcb7d62e power: Add global debug property for override config path properly
An init trigger would restart powerhal as early as the property was
loaded and it is hopefully early than any clients would try to connect.

Also remove the obsolete restart hook with audio.

Bug: 218872105
Test: boot
Signed-off-by: Wei Wang <wvw@google.com>
Change-Id: Ib55897f65709a963016b729f213718aae5af8e8c
2022-11-01 11:01:16 +00:00

33 lines
1.2 KiB
Plaintext

service vendor.power-hal-aidl /vendor/bin/hw/android.hardware.power-service.xiaomi-libperfmgr
class hal
user root
group system
priority -20
on late-fs
start vendor.power-hal-aidl
# Restart powerHAL when framework died
on property:init.svc.zygote=restarting && property:vendor.powerhal.state=*
setprop vendor.powerhal.state ""
setprop vendor.powerhal.audio ""
setprop vendor.powerhal.rendering ""
restart vendor.power-hal-aidl
# Clean up after b/163539793 resolved
on property:vendor.powerhal.dalvik.vm.dex2oat-threads=*
setprop dalvik.vm.dex2oat-threads ${vendor.powerhal.dalvik.vm.dex2oat-threads}
setprop dalvik.vm.restore-dex2oat-threads ${vendor.powerhal.dalvik.vm.dex2oat-threads}
on property:vendor.powerhal.dalvik.vm.dex2oat-cpu-set=*
setprop dalvik.vm.dex2oat-cpu-set ${vendor.powerhal.dalvik.vm.dex2oat-cpu-set}
setprop dalvik.vm.restore-dex2oat-cpu-set ${vendor.powerhal.dalvik.vm.dex2oat-cpu-set}
# Restart powerHAL when debug property set
on property:ro.debuggable=1 && property:vendor.powerhal.config.debug=*
restart vendor.power-hal-aidl
on property:persist.vendor.powerhal.config.debug=*
setprop vendor.powerhal.config.debug ${persist.vendor.powerhal.config.debug}