# MTK platform .rc configure import init.project.rc import init.xlog.rc import init.ssd.rc import init.modem.rc on early-boot # damn this is so easily overlooked mount debugfs debugfs /sys/kernel/debug chmod 0755 /sys/kernel/debug on init # BATTERY proc chown shell system /proc/mtk_battery_cmd/current_cmd chown shell system /proc/mtk_battery_cmd/discharging_cmd export USBOTG_STORAGE /storage/usbotg mount tmpfs tmpfs /mnt/media_rw/ mode=0755,uid=1000,gid=1000 mkdir /mnt/media_rw/usbotg 0700 media_rw media_rw mkdir /storage/usbotg 0700 root root mount tmpfs tmpfs /storage/usbotg mode=0755,uid=1000,gid=1000 chmod 0666 /dev/kmsg # Temp Backward compatibility mkdir /protect_f 0771 system system mkdir /protect_s 0771 system system #create mountpoint for persist partition mkdir /persist 0771 system system #Create nvdata mount point mkdir /nvdata 0771 system system # Temp Backward compatibility symlink /dev/block/platform/mtk-msdc.0/by-name/boot /dev/bootimg symlink /dev/block/platform/mtk-msdc.0/by-name/recovery /dev/recovery symlink /dev/block/platform/mtk-msdc.0/by-name/secro /dev/sec_ro symlink /dev/block/platform/mtk-msdc.0/by-name/kb /dev/kb symlink /dev/block/platform/mtk-msdc.0/by-name/dkb /dev/dkb symlink /dev/block/platform/mtk-msdc.0/by-name/seccfg /dev/seccfg symlink /dev/block/platform/mtk-msdc.0/by-name/proinfo /dev/pro_info symlink /dev/block/platform/mtk-msdc.0/by-name/nvram /dev/nvram symlink /dev/block/platform/mtk-msdc.0/by-name/para /dev/misc symlink /dev/block/platform/mtk-msdc.0/by-name/logo /dev/logo # Create CIP mount point mkdir /custom mkdir /mnt/cd-rom 0000 system system # Change ION driver permission chmod 0644 /dev/ion # change lk_env permission chown root system /proc/lk_env chmod 0660 /proc/lk_env #usbotg mkdir /mnt/media_rw/usbotg 0700 media_rw media_rw mkdir /storage/usbotg 0700 root root # mount different fs start on charger mount ext4 /dev/block/platform/mtk-msdc.0/by-name/system /system ro wait start fuelgauged start kpoc_charger start servicemanager on fs write /proc/bootprof "INIT:Mount_START" mount_all /fstab.mt6735 exec /system/bin/tune2fs -O has_journal -u 10010 -r 4096 /dev/block/platform/mtk-msdc.0/by-name/userdata #change partition permissions exec /system/bin/chmod 0640 /dev/block/platform/mtk-msdc.0/by-name/boot exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/boot exec /system/bin/chmod 0640 /dev/block/platform/mtk-msdc.0/by-name/recovery exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/recovery exec /system/bin/chmod 0640 /dev/block/platform/mtk-msdc.0/by-name/secro exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/secro exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/seccfg exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/seccfg exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/proinfo exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/proinfo exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/otp exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/otp exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/nvram exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/nvram exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/para exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/para exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/logo exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/logo exec /system/bin/chown root:system /dev/block/platform/mtk-msdc.0/by-name/frp exec /system/bin/chmod 0660 /dev/block/platform/mtk-msdc.0/by-name/frp write /proc/bootprof "INIT:Mount_END" on post-fs #change permissions for mediaserver chown root media /proc/clkmgr/mipi_test #change permission for engineer mode chown radio system /proc/clkmgr/clk_test chown radio system /proc/clkmgr/pll_test chown radio system /proc/clkmgr/pll_fsel chown radio system /proc/clkmgr/subsys_test chmod 0664 /proc/clkmgr/pll_test chmod 0664 /proc/clkmgr/pll_fsel #change permission for engineer mode chown radio system /proc/freqhopping/dramc chown radio system /proc/freqhopping/dumpregs chown radio system /proc/freqhopping/freqhopping_debug chown radio system /proc/freqhopping/status chown radio system /proc/freqhopping/userdef # change owner chown system system /proc/bootprof chown root system /proc/mtprof/cputime chown root system /proc/mtprof/reboot_pid chown system system /protect_f chmod 0770 /protect_f chown system system /protect_s chmod 0770 /protect_s chown system system /system/bin/sbchk chmod 0771 /system/bin/sbchk on post-fs-data chown system system /persist chmod 0771 /persist # create basic filesystem structure # mkdir /data/nvram 2770 root system # We chown/chmod /nvdata again so because mount is run as root + defaults chown root system /nvdata chmod 2770 /nvdata symlink /nvdata /data/nvram # Set SELinux security contexts on upgrade or policy update. restorecon_recursive /nvdata chmod 0660 /data/misc/wifi/p2p_supplicant.conf #give system access to rfkill device node chmod 0660 /dev/rfkill # create for muxd pts device node , to operate without root mkdir /dev/radio 0770 radio radio mkdir /data/drm/wv 0770 drm system # GPS mkdir /data/gps_mnl 0771 gps system mkdir /data/misc/gps 0770 gps gps # Wifi mkdir /data/misc/wifi/hostapd 0771 system wifi restorecon /data/misc/wifi/hostapd #restorecon /data/misc/wifi/hostapd/ap0 # ----------------------- # Add by MTK # md32 boot chown root system /dev/md32 chmod 0440 /dev/md32 chown root system /sys/class/misc/md32/md32_mobile_log chmod 0660 /sys/class/misc/md32/md32_mobile_log write /sys/class/misc/md32/md32_boot 1 # dhcp server mkdir /data/misc/dhcp 0770 dhcp wifi chown dhcp wifi /data/misc/dhcp # dhcpv6 server mkdir /data/misc/wide-dhcpv6 0770 dhcp wifi chown dhcp wifi /data/misc/wide-dhcpv6 # radvd mkdir /data/misc/radvd 0770 system system chmod 444 /etc/radvd/radvd.conf # Mali 3D GPU driver chmod 666 /dev/mali0 # Touch Panel chown root diag /sys/module/tpd_setting/parameters/tpd_calmat chown root diag /sys/module/tpd_setting/parameters/tpd_em_debounce_time chown root diag /sys/module/tpd_setting/parameters/tpd_mode chown root diag /sys/module/tpd_setting/parameters/tpd_em_debounce_time0 chown root diag /sys/module/tpd_setting/parameters/tpd_em_debounce_time1 chown root diag /sys/module/tpd_setting/parameters/tpd_em_spl_num chown root diag /sys/module/tpd_setting/parameters/tpd_em_pressure_threshold chown root diag /sys/module/tpd_setting/parameters/tpd_em_auto_time_interval chown root diag /sys/module/tpd_setting/parameters/tpd_em_sample_cnt chown root diag /sys/module/tpd_setting/parameters/tpd_em_asamp chown root diag /sys/module/tpd_debug/parameters/tpd_em_log chown root diag /sys/module/tpd_debug/parameters/tpd_em_log_to_fs chmod 0666 /dev/pmem_multimedia # watch dog kicker write /proc/wdk "0 20 30" # set ptmx group to non-root chown root radio /dev/ptmx # RTC mkdir /data/misc/rtc 0770 system system chown system system /dev/rtc0 chmod 0660 /dev/rtc0 # M4U chmod 0444 /dev/m4u #set mlock limit to infinate (for m4u operation) setrlimit 8 -1 -1 # CMDQ chmod 0640 /dev/mtk_cmdq chown system system /dev/mtk_cmdq #OFFLOAD SERVICE chmod 0640 /dev/offloadservice chown media media /dev/offloadservice # Sensor chmod 0660 /dev/hwmsensor chmod 0660 /dev/msensor chmod 0660 /dev/gsensor chmod 0660 /dev/als_ps chmod 0660 /dev/gyroscope chmod 0660 /dev/aal_als chmod 0660 /sys/devices/platform/msensor/driver/cpsopmode chmod 0660 /sys/devices/platform/msensor/driver/cpsreptxy chmod 0660 /sys/devices/platform/msensor/driver/cpsreptz chmod 0660 /sys/devices/platform/gsensor/driver/cpsopmode chmod 0660 /sys/devices/platform/gsensor/driver/cpsrange chmod 0660 /sys/devices/platform/gsensor/driver/cpsbandwidth chown system system /dev/hwmsensor chown system system /dev/msensor chown system system /dev/gsensor chown radio system /dev/als_ps chown system system /dev/gyroscope chown system system /dev/aal_als chmod 0660 /sys/class/misc/m_acc_misc/accenablenodata chmod 0660 /sys/class/misc/m_acc_misc/accactive chmod 0660 /sys/class/misc/m_acc_misc/accdelay chmod 0660 /sys/class/misc/m_acc_misc/accbatch chmod 0660 /sys/class/misc/m_acc_misc/accflush chown system system /sys/class/misc/m_acc_misc/accenablenodata chown system system /sys/class/misc/m_acc_misc/accactive chown system system /sys/class/misc/m_acc_misc/accdelay chown system system /sys/class/misc/m_acc_misc/accbatch chown system system /sys/class/misc/m_acc_misc/accflush #camera flashlight sysfs chmod 0644 /sys/class/flashlightdrv/kd_camera_flashlight/flash1 chmod 0644 /sys/class/flashlightdrv/kd_camera_flashlight/flash2 chown media system /sys/class/flashlightdrv/kd_camera_flashlight/flash1 chown media system /sys/class/flashlightdrv/kd_camera_flashlight/flash2 chmod 0660 /sys/class/misc/m_mag_misc/magactive chmod 0660 /sys/class/misc/m_mag_misc/magdelay chmod 0660 /sys/class/misc/m_mag_misc/magbatch chmod 0660 /sys/class/misc/m_mag_misc/magflush chmod 0660 /sys/class/misc/m_mag_misc/magoactive chmod 0660 /sys/class/misc/m_mag_misc/magodelay chmod 0660 /sys/class/misc/m_mag_misc/magobatch chmod 0660 /sys/class/misc/m_mag_misc/magoflush chown system system /sys/class/misc/m_mag_misc/magactive chown system system /sys/class/misc/m_mag_misc/magdelay chown system system /sys/class/misc/m_mag_misc/magbatch chown system system /sys/class/misc/m_mag_misc/magflush chown system system /sys/class/misc/m_mag_misc/magoactive chown system system /sys/class/misc/m_mag_misc/magodelay chown system system /sys/class/misc/m_mag_misc/magobatch chown system system /sys/class/misc/m_mag_misc/magoflush chmod 0660 /sys/class/misc/m_batch_misc/batchactive chmod 0660 /sys/class/misc/m_batch_misc/batchdelay chmod 0660 /sys/class/misc/m_batch_misc/batchbatch chmod 0660 /sys/class/misc/m_batch_misc/batchflush chown system system /sys/class/misc/m_batch_misc/batchactive chown system system /sys/class/misc/m_batch_misc/batchdelay chown system system /sys/class/misc/m_batch_misc/batchbatch chown system system /sys/class/misc/m_batch_misc/batchflush chmod 0660 /sys/class/misc/m_gyro_misc/gyroenablenodata chmod 0660 /sys/class/misc/m_gyro_misc/gyroactive chmod 0660 /sys/class/misc/m_gyro_misc/gyrodelay chmod 0660 /sys/class/misc/m_gyro_misc/gyrobatch chmod 0660 /sys/class/misc/m_gyro_misc/gyroflush chown system system /sys/class/misc/m_gyro_misc/gyroenablenodata chown system system /sys/class/misc/m_gyro_misc/gyroactive chown system system /sys/class/misc/m_gyro_misc/gyrodelay chown system system /sys/class/misc/m_gyro_misc/gyrobatch chown system system /sys/class/misc/m_gyro_misc/gyroflush chmod 0660 /sys/class/misc/m_alsps_misc/alsactive chmod 0660 /sys/class/misc/m_alsps_misc/alsdelay chmod 0660 /sys/class/misc/m_alsps_misc/alsbatch chmod 0660 /sys/class/misc/m_alsps_misc/alsflush chmod 0660 /sys/class/misc/m_alsps_misc/psactive chmod 0660 /sys/class/misc/m_alsps_misc/psdelay chmod 0660 /sys/class/misc/m_alsps_misc/psbatch chmod 0660 /sys/class/misc/m_alsps_misc/psflush chown system system /sys/class/misc/m_alsps_misc/alsactive chown system system /sys/class/misc/m_alsps_misc/alsdelay chown system system /sys/class/misc/m_alsps_misc/alsbatch chown system system /sys/class/misc/m_alsps_misc/alsflush chown system system /sys/class/misc/m_alsps_misc/psactive chown system system /sys/class/misc/m_alsps_misc/psdelay chown system system /sys/class/misc/m_alsps_misc/psbatch chown system system /sys/class/misc/m_alsps_misc/psflush chmod 0660 /sys/class/misc/m_baro_misc/baroenablenodata chmod 0660 /sys/class/misc/m_baro_misc/baroactive chmod 0660 /sys/class/misc/m_baro_misc/barodelay chmod 0660 /sys/class/misc/m_baro_misc/barobatch chmod 0660 /sys/class/misc/m_baro_misc/baroflush chown system system /sys/class/misc/m_baro_misc/baroenablenodata chown system system /sys/class/misc/m_baro_misc/baroactive chown system system /sys/class/misc/m_baro_misc/barodelay chown system system /sys/class/misc/m_baro_misc/barobatch chown system system /sys/class/misc/m_baro_misc/baroflush #Accdet chown root radio /sys/devices/platform/Accdet_Driver/driver/accdet_call_state #VideoCodec mknod /dev/Vcodec c 160 0 chmod 0660 /dev/Vcodec chown system media /dev/Vcodec #MJC #mknod /dev/MJC c 168 0 chmod 0660 /dev/MJC chown system media /dev/MJC #kpd chown radio radio /sys/devices/platform/mtk-kpd/driver/kpd_call_state #Charging Battery chown radio radio /sys/devices/platform/battery/Charging_CallState # PMIC property chown radio system /sys/devices/platform/mt-pmic/low_battery_protect_stop chown radio system /sys/devices/platform/mt-pmic/low_battery_protect_ut mkdir /data/amit/ 0770 system system mkdir /data/misc/sensor 0774 system system mkdir /data/misc/akmd 0770 system system mkdir /data/misc/s62x 0771 compass compass mkdir /data/acdapi/ 0770 system system chmod 0666 /data/misc/acdapi/calib.dat chmod 0666 /data/misc/acdapi/param.dat chmod 0666 /data/misc/acdapi/sensors.dat chown system /sys/devices/platform/msensor/driver/cpsopmode chown system /sys/devices/platform/msensor/driver/cpsreptxy chown system /sys/devices/platform/msensor/driver/cpsreptz chown system /sys/devices/platform/gsensor/driver/cpsopmode chown system /sys/devices/platform/gsensor/driver/cpsrange mkdir /data/data/mcube 0664 system system chown system /sys/class/input/input1/enable chown system /sys/class/input/input1/delay chown system /sys/class/input/input1/wake chown system /sys/class/input/input1/offsets chown system /sys/class/input/input2/enable chown system /sys/class/input/input2/delay chown system /sys/class/input/input2/wake chown system /sys/class/input/input2/offsets chown system /sys/class/input/input3/enable chown system /sys/class/input/input3/delay chown system /sys/class/input/input3/wake chown system /sys/class/input/input3/offsets chown system /sys/class/input/input4/enable chown system /sys/class/input/input4/delay chown system /sys/class/input/input4/wake chown system /sys/class/input/input4/offsets chown system /sys/class/input/input5/enable chown system /sys/class/input/input5/delay chown system /sys/class/input/input5/wake chown system /sys/class/input/input5/offsets chown system /sys/class/input/input6/enable chown system /sys/class/input/input6/delay chown system /sys/class/input/input6/wake chown system /sys/class/input/input6/offsets chown system /sys/class/input/input7/enable chown system /sys/class/input/input7/delay chown system /sys/class/input/input7/wake chown system /sys/class/input/input7/offsets chown system /sys/class/input/input8/enable chown system /sys/class/input/input8/delay chown system /sys/class/input/input8/wake chown system /sys/class/input/input8/offsets chown system /sys/class/input/input9/enable chown system /sys/class/input/input9/delay chown system /sys/class/input/input9/wake chown system /sys/class/input/input9/offsets chown system /sys/class/input/input10/enable chown system /sys/class/input/input10/delay chown system /sys/class/input/input10/wake chown system /sys/class/input/input10/offsets #EM eint chown root diag /sys/bus/platform/drivers/eint/current_eint # Display chmod 0660 /dev/graphics/fb0 chown system graphics /dev/graphics/fb0 chmod 0660 /dev/mtk_disp_mgr chown system graphics /dev/mtk_disp_mgr # Live Display chmod 0660 /sys/devices/platform/mtk_disp_mgr.0/rgb chown system system /sys/devices/platform/mtk_disp_mgr.0/rgb chmod 0660 /dev/mtkfb_vsync chown system graphics /dev/mtkfb_vsync chmod 0660 /dev/sw_sync chown system graphics /dev/sw_sync # EM baseband file chown root diag /system/bin/baseband_regdump chmod 4750 /system/bin/baseband_regdump #pmu chown root radio /sys/devices/platform/mt-pmic/pmic_access_bank0 chown root radio /sys/devices/platform/mt-pmic/pmic_access_bank1 chown root radio /sys/devices/platform/mt6311-user/mt6311_access chown root radio /sys/devices/platform/mt-pmic/pmic_access chmod 0664 /sys/devices/platform/mt-pmic/pmic_access_bank0 chmod 0664 /sys/devices/platform/mt-pmic/pmic_access_bank1 chmod 0664 /sys/devices/platform/mt6311-user/mt6311_access chmod 0664 /sys/devices/platform/mt-pmic/pmic_access # EM CPU Speed Stress chown root radio /proc/cpu_ss/cpu_ss_debug_mode chown root radio /proc/cpu_ss/cpu_ss_mode chown root radio /proc/cpu_ss/cpu_ss_period chown root radio /proc/cpu_ss/cpu_ss_period_mode chmod 0664 /proc/cpu_ss/cpu_ss_debug_mode chmod 0664 /proc/cpu_ss/cpu_ss_mode chmod 0664 /proc/cpu_ss/cpu_ss_period chmod 0664 /proc/cpu_ss/cpu_ss_period_mode # for ppp options file mkdir /data/misc/ppp 0770 bluetooth net_bt # Android SEC related device nodes chmod 0660 /dev/sec chown root system /dev/sec # device apc settings # device info /proc interface mknod /dev/devmap c 196 0; chmod 0440 /dev/devmap chown root system /dev/devmap # BT relayer mode used VCOM chown bluetooth radio /dev/ttyGS2 chmod 0660 /dev/ttyGS2 # bluetooth mkdir /data/@btmtk 0770 bluetooth net_bt chown bluetooth bluetooth /data/@btmtk/host_cache chown bluetooth bluetooth /data/@btmtk/dev_cache chown bluetooth bluetooth /dev/hid-keyboard chmod 0660 /dev/hid-keyboard #Use uinput's default permission chown system net_bt_admin /dev/uinput # UIBC chown system media /dev/uibc chmod 0660 /dev/uibc #TV-out chmod 0664 /dev/TV-out #HDMI chmod 0664 /dev/hdmitx chmod 0660 /dev/hdmitx # JPEG #chmod 0444 /dev/mtk_jpeg # almk chmod 0440 /dev/mtk_almk # DISP chmod 0444 /dev/mtk_disp #Camera chmod 0660 /dev/camera-sysram chmod 0660 /dev/camera-isp chmod 0660 /dev/camera-fdvt chmod 0660 /dev/camera-pipemgr chmod 0660 /dev/kd_camera_hw chmod 0660 /dev/kd_camera_flashlight chmod 0660 /dev/kd_camera_hw_bus2 chmod 0660 /dev/BU64245 chmod 0660 /dev/CAM_CAL_DRV chmod 0660 /dev/CAM_CAL_DRV_SUB chown system camera /dev/camera-sysram chown system camera /dev/camera-isp chown system camera /dev/camera-fdvt chown system camera /dev/camera-pipemgr chown system camera /dev/kd_camera_hw chown system camera /dev/kd_camera_flashlight chown system camera /dev/kd_camera_hw_bus2 chown system camera /dev/BU64245 chown system camera /dev/CAM_CAL_DRV chown system camera /dev/CAM_CAL_DRV_SUB #MATV chmod 0660 /dev/MATV chown system media /dev/MATV # otg_test chown root radio /dev/mt_otg_test chmod 0660 /dev/mt_otg_test # MDP chmod 0660 /dev/mt-mdp chown system media /dev/mt-mdp # SMI chmod 0660 /dev/MTK_SMI chown system media /dev/MTK_SMI #change partition permission chmod 0640 /mtd@sec_ro chown root system /mtd@sec_ro chmod 0640 /mtd@preloader chown root system /mtd@preloader chmod 0660 /mtd@pro_info chown root system /mtd@pro_info chmod 0640 /mtd@bootimg chown root system /mtd@bootimg chmod 0640 /mtd@recovery chown root system /mtd@recovery chmod 0660 /mtd@nvram chown root system /mtd@nvram chmod 0660 /mtd@seccfg chown root system /mtd@seccfg chmod 0660 /mtd@misc chown root system /mtd@misc chmod 0664 /sys/bus/platform/drivers/mem_bw_ctrl/concurrency_scenario chown system media /sys/bus/platform/drivers/mem_bw_ctrl/concurrency_scenario #mtk_sched chmod 0660 /dev/mtk_sched chown system media /dev/mtk_sched #BT SCO CVSD, for MT6572 and MT6582 CVSD codec on AP chmod 0660 /dev/ebc chown system media /dev/ebc chmod 0666 /dev/uio0 #otp chmod 0660 /proc/driver/otp chown root system /proc/driver/otp #autok chown root system /sys/autok/debug chown root system /sys/autok/param_count chown root system /sys/autok/ready chown root system /sys/autok/ss_corner chown root system /sys/autok/suggest_vol chown root system /sys/autok/stage1/2/DONE chown root system /sys/autok/stage1/2/PARAMS chown root system /sys/autok/stage1/2/VOLTAGE chown root system /sys/autok/stage1/2/LOG chown root system /sys/autok/stage2/2 # secure memory chown system system /proc/secmem0 # mcDriverDaemon mkdir /data/app/mcRegistry 0770 system system mkdir /data/app/mcRegistry/TbStorage 0770 system system # AGPS mkdir /data/agps_supl 0771 gps system # Recycle stuffs exec /system/bin/rm -f /cache/.ipoh.img chmod 0666 /dev/exm0 # End of adding by MTK drivers # ----------------------- # ----------------------- # Add by MEIZU BSP setprop ro.product.mobile.name m81 # End of adding by MEIZU BSP drivers # ----------------------- on boot # xlog start xlogboot chmod 0444 /proc/cmdline write /proc/sys/vm/dirty_writeback_centisecs 300 chmod 0660 /sys/power/autosleep chmod 0664 /sys/class/leds/lcd-backlight/brightness chown system system /sys/devices/system/cpu/cpufreq/hotplug/cpu_num_base chmod 0660 /sys/devices/system/cpu/cpufreq/hotplug/cpu_num_base chown root system /sys/kernel/debug/binder/transaction_log_enable chown root system /sys/kernel/debug/binder/perf_evalue chown system /sys/module/mlog/parameters/do_mlog chown system /sys/module/mlog/parameters/timer_intval chown root radio /sys/class/leds/lcd-backlight/duty chown root radio /sys/class/leds/lcd-backlight/div chown system system /sys/class/leds/lcd-backlight/trigger chown system system /sys/class/leds/button-backlight/trigger chown system system /sys/class/leds/keyboard-backlight/trigger chown system system /sys/class/leds/jogball-backlight/trigger chown system system /sys/class/leds/red/trigger chown system system /sys/class/leds/green/trigger chown system system /sys/class/leds/blue/trigger # Add by Meizu BSP@YinShunQing for button LED blink chown system system /sys/class/leds/button-backlight/oneshot_blink # Permission for hibernation chown radio system /sys/power/tuxonice chown radio system /sys/power/tuxonice/do_hibernate chmod 0770 /sys/power/tuxonice chmod 0220 /sys/power/tuxonice/do_hibernate # Smartbook Handler Framework chown system system /sys/power/sb_state chmod 0660 /sys/power/sb_state # HMP CPU hotplug strategy chown system system /proc/hps/num_base_perf_serv chmod 0660 /proc/hps/num_base_perf_serv chown system system /proc/hps/num_limit_power_serv chmod 0660 /proc/hps/num_limit_power_serv chown system system /proc/hps/num_limit_ultra_power_saving chmod 0660 /proc/hps/num_limit_ultra_power_saving chown system system /proc/hps/down_threshold chmod 0660 /proc/hps/down_threshold chown system system /proc/hps/up_threshold chmod 0660 /proc/hps/up_threshold # CPU freq chown system system /proc/cpufreq/cpufreq_limited_by_hevc chmod 0660 /proc/cpufreq/cpufreq_limited_by_hevc chown system system /proc/cpufreq/cpufreq_limited_max_freq_by_user chmod 0660 /proc/cpufreq/cpufreq_limited_max_freq_by_user ##Netlog tool #change permissions about terminal chown root radio /proc/net/vlan/config chmod 0640 /proc/net/vlan/config chown root radio /proc/net/ip6_tables_matches chown root radio /proc/net/ip6_tables_names chown root radio /proc/net/ip6_tables_targets chown root radio /proc/net/arp_tables_targets chown root radio /proc/net/arp_tables_matches chown root radio /proc/net/arp_tables_names chown root radio /proc/net/ip_tables_targets chown root radio /proc/net/ip_tables_matches chown root radio /proc/net/ip_tables_names chown root radio /proc/net/ip_conntrack_expect chown root radio /proc/net/ip_conntrack chown root radio /proc/net/nf_conntrack chown root radio /proc/net/nf_conntrack_expect chown root radio /proc/net/netfilter/nfnetlink_log chown root radio /proc/net/netfilter/nfnetlink_queue # WMT proc chown shell system /proc/driver/wmt_dbg chown shell system /proc/driver/wmt_aee # define device for EMCSMDLOGGER chown system radio /dev/ttyGS3 chmod 0660 /dev/ttyGS3 #Define device for ATCID chmod 660 /dev/ttyGS0 chown system /dev/ttyGS0 chmod 660 /dev/ttyGS1 chown system /dev/ttyGS1 on property:ro.board.platform=mt6753 chown system system /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq write /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq 1300000 on property:vold.decrypt=trigger_reset_main start stop_modem write /proc/bootprof "trigger_reset_main" on property:vold.decrypt=trigger_restart_min_framework start start_modem start msensord start permission_check write /proc/bootprof "trigger_restart_min_framework" on property:vold.decrypt=trigger_restart_framework start nvram_daemon start start_modem start msensord start permission_check write /proc/bootprof "trigger_restart_framework" on property:vold.decrypt=trigger_shutdown_framework start stop_modem start swapoff_action write /proc/bootprof "trigger_shutdown_framework" service stop_modem /system/bin/md_ctrl 0 class main disabled oneshot service start_modem /system/bin/md_ctrl 1 class main disabled oneshot # Define TCP buffer sizes for various networks # ReadMin, ReadInitial, ReadMax, WriteMin, WriteInitial, WriteMax, setprop net.tcp.buffersize.default 4096,87380,524288,4096,16384,524288 setprop net.tcp.buffersize.wifi 524288,1048576,2097152,262144,524288,1048576 setprop net.tcp.buffersize.lte 524288,1048576,2097152,262144,524288,1048576 setprop net.tcp.buffersize.umts 4094,87380,524288,4096,16384,524288 setprop net.tcp.buffersize.hspa 4094,87380,524288,4096,16384,524288 setprop net.tcp.buffersize.hsupa 4094,87380,524288,4096,16384,524288 setprop net.tcp.buffersize.hsdpa 4094,87380,524288,4096,16384,524288 setprop net.tcp.buffersize.hspap 4094,87380,1220608,4096,16384,1220608 setprop net.tcp.buffersize.edge 4093,26280,35040,4096,16384,35040 setprop net.tcp.buffersize.gprs 4092,8760,11680,4096,8760,11680 setprop persist.sys.strictmode.disable 1 ## mtk printk uart controller on property:persist.uartconsole.enable=1 write /proc/mtprintk 1 service fuse_usbotg /system/bin/sdcard -u 1023 -g 1023 -w 1023 -d /mnt/media_rw/usbotg /storage/usbotg class late_start disabled # bugreport is triggered by holding down volume down, volume up and power service bugreport /system/bin/dumpstate -d -p -B \ -o /data/data/com.android.shell/files/bugreports/bugreport class main disabled oneshot keycodes 114 115 116 service netdiag /system/bin/netdiag class main socket netdiag stream 0660 root inet service nvram_daemon /system/bin/nvram_daemon class main user root group system oneshot service atci_service /system/bin/atci_service class core socket atci-service stream 660 radio system socket atci-serv-fw stream 660 radio system user root disabled group radio system service atcid-daemon-u /system/bin/atcid class main socket adb_atci_socket stream 660 radio system user system group radio system media inet wifi net_admin disabled oneshot service atcid-daemon-e /system/bin/atcid class core socket adb_atci_socket stream 660 radio system user root group radio system disabled oneshot on property:persist.service.atci.usermode=1 setprop persist.sys.usb.config mass_storage,adb,acm on property:ro.build.type=eng start atci_service start atcid-daemon-e service audio-daemon /system/bin/audiocmdservice_atci class main socket atci-audio stream 660 root system user root disabled oneshot service pq /system/bin/pq class main user system group system graphics oneshot # # MTK Wi-Fi related services (Begin) # # monitor property and power on/off wlan on property:wlan.driver.status=ok write /dev/wmtWifi "1" on property:wlan.driver.status=unloaded write /dev/wmtWifi "0" service p2p_supplicant /system/bin/wpa_supplicant \ -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \ -I/system/etc/wifi/wpa_supplicant_overlay.conf -N \ -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf -e/data/misc/wifi/entropy.bin \ -I/system/etc/wifi/p2p_supplicant_overlay.conf \ -O/data/misc/wifi/sockets -g@android:wpa_wlan0 # we will start as root and wpa_supplicant will switch to user wifi # after setting up the capabilities required for WEXT # user wifi # group wifi inet keystore class main socket wpa_wlan0 dgram 660 wifi wifi disabled oneshot service wpa_supplicant /system/bin/wpa_supplicant \ -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf -e/data/misc/wifi/entropy.bin \ -I/system/etc/wifi/wpa_supplicant_overlay.conf \ -O/data/misc/wifi/sockets -g@android:wpa_wlan0 # we will start as root and wpa_supplicant will switch to user wifi # after setting up the capabilities required for WEXT # user wifi # group wifi inet keystore class main socket wpa_wlan0 dgram 660 wifi wifi disabled oneshot # For WiFi High Speed calibration service autokd /system/bin/autokd class core user system group system # # MTK Wi-Fi related services (End) # service dhcpcd_bt-pan /system/bin/dhcpcd -ABKL class main user root group net_admin net_raw disabled oneshot service dhcpcd_wlan0 /system/bin/dhcpcd -aABKL class main user root group net_admin net_raw disabled oneshot service dhcpcd_p2p /system/bin/dhcpcd -aABKL class main user root group net_admin net_raw disabled oneshot service iprenew_wlan0 /system/bin/dhcpcd -n class main user dhcp group net_admin net_raw disabled oneshot service iprenew_p2p /system/bin/dhcpcd -n class main user dhcp group net_admin net_raw disabled oneshot service dhcp_inform /system/bin/dhcpcd -s -BK -A class main user root group system radio dhcp net_admin net_raw disabled oneshot service dhcpv6_inform /system/bin/dhcp6c -c "/etc/wide-dhcpv6/dhcp6cSIP.conf" -fi class main user root group system radio dhcp net_admin net_raw disabled oneshot service dhcp6cDNS_wlan0 /system/bin/dhcp6c -c "/etc/wide-dhcpv6/dhcp6cDNS.conf" -f wlan0 disabled oneshot service dhcp6c_wlan0 /system/bin/dhcp6c -c "/etc/wide-dhcpv6/dhcp6c.conf" -f wlan0 disabled oneshot on property:service.dhcp6c_wlan0.enable=0 stop dhcp6c_wlan0 on property:service.dhcp6c_wlan0.enable=1 start dhcp6c_wlan0 service dhcp6c_PD /system/bin/dhcp6c -c "/etc/wide-dhcpv6/dhcp6cPD.conf" -f disabled oneshot # write proc for test sim on property:gsm.sim.ril.testsim=0 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 0 write /proc/sys/net/ipv4/tcp_rto_min 200 on property:gsm.sim.ril.testsim=1 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 1 write /proc/sys/net/ipv4/tcp_rto_min 400 on property:gsm.sim.ril.testsim.2=0 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 0 write /proc/sys/net/ipv4/tcp_rto_min 200 on property:gsm.sim.ril.testsim.2=1 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 1 write /proc/sys/net/ipv4/tcp_rto_min 400 on property:gsm.sim.ril.testsim.3=0 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 0 write /proc/sys/net/ipv4/tcp_rto_min 200 on property:gsm.sim.ril.testsim.3=1 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 1 write /proc/sys/net/ipv4/tcp_rto_min 400 on property:gsm.sim.ril.testsim.4=0 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 0 write /proc/sys/net/ipv4/tcp_rto_min 200 on property:gsm.sim.ril.testsim.4=1 write /proc/sys/net/netfilter/nf_conntrack_tcp_no_window_check 1 write /proc/sys/net/ipv4/tcp_rto_min 400 service PPLAgent /system/bin/ppl_agent class main user system group system cache service bluetoothd /system/bin/bluetoothd -n class main socket bluetooth stream 660 bluetooth bluetooth socket dbus_bluetooth stream 660 bluetooth bluetooth # init.rc does not yet support applying capabilities, so run as root and # let bluetoothd drop uid to bluetooth with the right linux capabilities group bluetooth net_bt_admin misc disabled service mtkbt /system/bin/mtkbt class late_start socket bt.int.adp dgram 660 bluetooth net_bt socket bt.a2dp.stream dgram 660 bluetooth net_bt user bluetooth group system vpn net_admin inet net_raw net_bt bluetooth net_bt_admin net_bt_stack sdcard_r oneshot # # External Modem control related services # # # Modem related services (Begin) # service pppd_gprs /system/bin/pppd_dt /dev/ttyACM0 debug noauth refuse-eap usepeerdns nodetach user root group radio cache inet misc disabled oneshot # # Modem related services (End) # service agpsd /system/bin/mtk_agpsd class main socket agpsd stream 660 gps system socket agpsd2 stream 660 gps inet socket agpsd3 stream 660 gps inet user gps group gps radio inet sdcard_r sdcard_rw misc service mnld /system/xbin/mnld class main user gps group gps inet misc sdcard_rw sdcard_r media_rw system socket mnld stream 660 gps system # #sensor service (begin) # service msensord /system/bin/msensord class main oneshot service s62xd /system/bin/s62xd disabled user compass group system class main service ami304d /system/bin/ami304d user system group system disabled class main service memsicd /system/bin/memsicd disabled user system group system class main service memsicd3416x /system/bin/memsicd3416x disabled user system group system class main service akmd8975 /system/bin/akmd8975 disabled user system group system class main service akmd8963 /system/bin/akmd8963 disabled user system group system class main service akmd09911 /system/bin/akmd09911 disabled user system group system class main service bmm050d /system/bin/bmm050d disabled user system group system class main service bmm056d /system/bin/bmm056d disabled user system group system class main service mc6420d /system/bin/mc6420d disabled user system group system class main service qmc5983d /system/bin/qmc5983d disabled user system group system class main service orientationd /system/bin/orientationd disabled user system group system input class main service AcdApiDaemon /system/bin/AcdApiDaemon disabled user system group system class main service geomagneticd /system/bin/geomagneticd disabled user system group system input class main service mpud6050 /system/bin/mpud6050 oneshot user system group system service mc64xxd /system/bin/mc64xxd disabled user system group system class main # #sensor service (end) # # # emsvr service (start) # service emsvr /system/bin/em_svr class main user system group system radio diag # # emsvr service (end) # service NvRAMAgent /system/bin/nvram_agent_binder class main user system group system service thermal_manager /system/bin/thermal_manager class main user root oneshot service thermal /system/bin/thermal class main user system group system service thermald /system/bin/thermald class main user system group system service fuelgauged /system/bin/fuelgauged class main user system group system service MtkCodecService /system/bin/MtkCodecService class main user system group audio media sdcard_r # GuiExt Server init service guiext-server /system/bin/guiext-server class main user system group system graphics service kpoc_charger /system/bin/kpoc_charger class charger ###########add for 3Gdongle on boot # # change the right of ip-up ip-down scripts(begin) # chmod 777 /etc/ppp/ip-up chmod 777 /etc/ppp/ip-down # # change the right of ip-up ip-down scripts(end) # # # change the right of ip-up-ppp0 ip-down-ppp0 scripts(begin) # chmod 777 /etc/ppp/ip-up-ppp0 chmod 777 /etc/ppp/ip-down-ppp0 # # change the right of ip-up ip-down scripts(end) # #set the property of persiste.radio.reset_on_switch setprop persist.radio.reset_on_switch true #end #set the property of rild.mark_switchuser setprop rild.mark_switchuser 0 #end