Samsung has two android.hardware.power HAL. Take appropriate one.

Samsung includes both stock AOSP android.hardware.power service, and
their own vendor.samsung.hardware.miscpower.

Since the two HALs define the same full-qualified name, hwservicemanager
takes whichever comes last.

Using proper power HAL is needed for Samsung device to have proper sleep
of the touchscreen, and better power handling.
This commit is contained in:
Pierre-Hugues Husson 2018-09-09 21:38:33 +02:00
parent 229e74b438
commit e064c6f310
1 changed files with 4 additions and 0 deletions

View File

@ -145,3 +145,7 @@ if grep -qF 'PowerVR Rogue GE8100' /vendor/lib/egl/GLESv1_CM_mtk.so;then
setprop debug.hwui.renderer opengl
fi
#If we have both Samsung and AOSP power hal, take Samsung's
if [ -f /vendor/bin/hw/vendor.samsung.hardware.miscpower@1.0-service ];then
mount -o bind /system/phh/empty /vendor/bin/hw/android.hardware.power@1.0-service
fi