blob: 83e7b6d9926afddcd26135442ca6364ab835c20b [file] [log] [blame]
Pierre-Hugues Husson6eaf5012018-05-14 17:04:27 +02001#!/system/bin/sh
2
Pierre-Hugues Husson26bc3e72018-08-29 20:36:21 +02003[ "$(getprop vold.decrypt)" == "trigger_restart_min_framework" ] && exit 0
4
Aren Cleggd6aa9592018-08-05 01:36:48 +00005if [ "$(getprop ro.vendor.product.device)" == "HWBKL" ];then
6 phh-su -c 'mount -o remount,rw /system'
Aren Clegg72325ce2018-08-05 07:04:03 +00007 phh-su -c 'pm uninstall --user 0 com.android.camera2'
Aren Cleggd6aa9592018-08-05 01:36:48 +00008 phh-su -c 'mount -o remount,ro /system'
9else
10 phh-su -c 'mount -o remount,rw /system'
Aren Clegg72325ce2018-08-05 07:04:03 +000011 phh-su -c 'pm uninstall --user 0 com.huawei.camera'
Aren Cleggd6aa9592018-08-05 01:36:48 +000012 phh-su -c 'mount -o remount,ro /system'
13fi
14
Pierre-Hugues Hussond50cffe2018-08-28 14:53:16 +020015if [ -f /vendor/bin/mtkmal ];then
Pierre-Hugues Husson26bc3e72018-08-29 20:36:21 +020016 if [ "$(getprop persist.mtk_ims_support)" == 1 -o "$(getprop persist.mtk_epdg_support)" == 1 ];then
Pierre-Hugues Hussond50cffe2018-08-28 14:53:16 +020017 setprop persist.mtk_ims_support 0
18 setprop persist.mtk_epdg_support 0
19 reboot
20 fi
21fi
22
Pierre-Hugues Hussonaea19262018-07-18 23:46:34 +020023#Clear looping services
Pierre-Hugues Husson6eaf5012018-05-14 17:04:27 +020024sleep 30
25getprop | \
26 grep restarting | \
27 sed -nE -e 's/\[([^]]*).*/\1/g' -e 's/init.svc.(.*)/\1/p' |
28 while read svc ;do
29 setprop ctl.stop $svc
30 done
Pierre-Hugues Hussonca0ed802018-08-22 11:01:43 +020031
32if grep -qF android.hardware.boot /vendor/manifest.xml;then
33 bootctl mark-boot-successful
34fi