Disable soundvolume effect on Xiaomi Mi 11 Lite 5G

Fixes audio distorsion on this device and may fix on other Qualcomm devices
This commit is contained in:
Alberto Ponces 2021-12-02 09:52:32 +00:00
parent 06a00ae37c
commit 66cc06b0a9
2 changed files with 19 additions and 0 deletions

View File

@ -184,3 +184,19 @@ if [ "$1" == "persist.sys.phh.backlight.scale" ];then
fi
exit
fi
if [ "$1" == "persist.sys.phh.disable_soundvolume_effect" ];then
if [[ "$prop_value" != "0" && "$prop_value" != "1" ]]; then
exit 1
fi
if [[ "$prop_value" == 1 ]];then
mount /system/phh/empty /vendor/lib/soundfx/libvolumelistener.so
mount /system/phh/empty /vendor/lib64/soundfx/libvolumelistener.so
else
umount /vendor/lib/soundfx/libvolumelistener.so
umount /vendor/lib64/soundfx/libvolumelistener.so
fi
restartAudio
exit
fi

View File

@ -47,6 +47,9 @@ on property:persist.sys.phh.vsmart.dt2w=*
on property:persist.sys.phh.backlight.scale=*
exec u:r:phhsu_daemon:s0 root -- /system/bin/phh-prop-handler.sh "persist.sys.phh.backlight.scale"
on property:persist.sys.phh.disable_soundvolume_effect=*
exec u:r:phhsu_daemon:s0 root -- /system/bin/phh-prop-handler.sh "persist.sys.phh.disable_soundvolume_effect"
on property:ro.sf.lcd_density=*
restart surfaceflinger