NX669J: Use audio config from QSSI

AOSP doesn't care about QSSI, and it will always try to load from
/vendor/etc/audio/sku_{ro.boot.product.vendor.sku}, while the stock ROM
loads from /vendor/etc/audio/sku_{ro.boot.product.vendor.sku}_qssi.

This fixes speaker and headphone audio for Nubia Red Magic 6.
This commit is contained in:
notsyncing 2021-03-16 19:38:34 +08:00
parent 2057f5d25a
commit d190d02990

View File

@ -617,6 +617,13 @@ if getprop ro.vendor.build.fingerprint | grep -qiE '^samsung/' && [ "$vndk" -ge
fi
fi
# For Nubia Red Magic 6 audio policy configuration
if getprop ro.vendor.build.fingerprint | grep -q -e nubia/NX669; then
umount /vendor/etc/audio
sku="$(getprop ro.boot.product.vendor.sku)"
mount /vendor/etc/audio/sku_${sku}_qssi/audio_policy_configuration.xml /vendor/etc/audio/sku_$sku/audio_policy_configuration.xml
fi
setprop ctl.stop console
dmesg -n 1
if [ -f /system/phh/secure ];then