1#!/vendor/bin/sh 2 3# 4# Copy qcril.db if needed for RIL 5# 6if [ -f /vendor/qcril.db -a ! -f /data/misc/radio/qcril.db ]; then 7 cp /vendor/qcril.db /data/misc/radio/qcril.db 8 chown -h radio.radio /data/misc/radio/qcril.db 9fi 10echo 1 > /data/misc/radio/db_check_done 11 12# 13# Make modem config folder and copy firmware config to that folder for RIL 14# 15if [ -f /data/misc/radio/ver_info.txt ]; then 16 prev_version_info=`cat /data/misc/radio/ver_info.txt` 17else 18 prev_version_info="" 19fi 20 21cur_version_info=`cat /firmware/radio/modem_pr/verinfo/ver_info.txt` 22if [ ! -f /firmware/radio/modem_pr/verinfo/ver_info.txt -o "$prev_version_info" != "$cur_version_info" ]; then 23 rm -rf /data/misc/radio/modem_config 24 rm /data/misc/radio/ver_info.txt 25 mkdir /data/misc/radio/modem_config 26 chmod 770 /data/misc/radio/modem_config 27 cp -r /firmware/radio/modem_pr/mcfg/configs/* /data/misc/radio/modem_config 28 chown -hR radio.radio /data/misc/radio/modem_config 29 cp /firmware/radio/modem_pr/verinfo/ver_info.txt /data/misc/radio/ver_info.txt 30 chown radio.radio /data/misc/radio/ver_info.txt 31fi 32echo 1 > /data/misc/radio/copy_complete 33