blob: 274c9f1d9b9e7354951f3c8eb1528f3dd6af6c46 [file] [log] [blame]
import init.manta.usb.rc
on init
start watchdogd
# See storage config details at http://source.android.com/tech/storage/
mkdir /mnt/shell/emulated 0700 shell shell
mkdir /storage/emulated 0000 root root
mkdir /storage/emulated_legacy 0000 root root
export EXTERNAL_STORAGE /storage/emulated_legacy
export ADB_EXTERNAL_STORAGE /mnt/shell/emulated/0
export EMULATED_STORAGE_SOURCE /mnt/shell/emulated
export EMULATED_STORAGE_TARGET /storage/emulated
# Support legacy paths
symlink /storage/emulated_legacy /sdcard
symlink /storage/emulated_legacy /mnt/sdcard
symlink /storage/emulated_legacy /storage/sdcard0
on post-fs-data
mkdir /data/media 0770 media_rw media_rw
setprop vold.post_fs_data_done 1
mkdir /data/misc/wifi 0770 wifi wifi
mkdir /data/misc/wifi/sockets 0770 wifi wifi
mkdir /data/misc/dhcp 0770 dhcp dhcp
chown dhcp dhcp /data/misc/dhcp
# permissions for bluetooth.
setprop ro.bt.bdaddr_path "/efs/bluetooth/bt_addr"
chown bluetooth bluetooth ro.bt.bdaddr_path
chown bluetooth bluetooth /dev/ttySAC0
chmod 0600 /dev/ttySAC0
chmod 0660 /sys/class/rfkill/rfkill0/state
chown bluetooth bluetooth /sys/class/rfkill/rfkill0/state
chown bluetooth bluetooth /sys/class/rfkill/rfkill0/type
on boot
mount debugfs /sys/kernel/debug /sys/kernel/debug
setprop ro.radio.noril yes
# Set up kernel tracing, but disable it by default
chmod 0222 /sys/kernel/debug/tracing/trace_marker
write /sys/kernel/debug/tracing/tracing_on 0
chmod 0444 /sys/kernel/debug/smb347-regs
on fs
mkdir /factory 0775 radio radio
mount_all /fstab.manta
setprop ro.crypto.fuse_sdcard true
# Permissions for backlight
chmod 0660 /sys/class/backlight/pwm-backlight.0/brightness
chown system system /sys/class/backlight/pwm-backlight.0/brightness
# create data/gps for GPS daemon
chown root system /sys/class/gps/bcm475x/GPS_PWR_EN/value
chmod 0664 /sys/class/gps/bcm475x/GPS_PWR_EN/value
chown root system /sys/class/gps/bcm475x/GPS_nRST/value
chmod 0664 /sys/class/gps/bcm475x/GPS_nRST/value
mkdir /data/gps 771 system system
chown system system /data/gps
# NFC: create data/nfc for nv storage
mkdir /data/nfc 770 nfc nfc
mkdir /data/nfc/param 770 nfc nfc
# virtual sdcard daemon running as media_rw (1023)
service sdcard /system/bin/sdcard /data/media /mnt/shell/emulated 1023 1023
class late_start
service p2p_supplicant /system/bin/wpa_supplicant \
-iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \
-puse_multi_chan_concurrent=1 -N -ip2p0 -Dnl80211 \
-c/data/misc/wifi/p2p_supplicant.conf \
-puse_p2p_group_interface=1use_multi_chan_concurrent=1 -e/data/misc/wifi/entropy.bin
# 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
# 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 dhcpcd_wlan0 /system/bin/dhcpcd -aABKL
class main
disabled
oneshot
service dhcpcd_p2p /system/bin/dhcpcd -aABKL
class main
disabled
oneshot
service dhcpcd_eth0 /system/bin/dhcpcd -ABKL
class main
disabled
oneshot
service iprenew_wlan0 /system/bin/dhcpcd -n
class main
disabled
oneshot
service iprenew_p2p /system/bin/dhcpcd -n
class main
disabled
oneshot
service battery_charger /charger
class charger
# Set watchdog timer to 30 seconds and pet it every 10 seconds to get a 20 second margin
service watchdogd /sbin/watchdogd 10 20
class core
service gpsd /system/vendor/bin/gpsd -c /system/vendor/etc/gps.xml
class main
socket gps seqpacket 0660 gps system
user gps
group system inet
# MobiCore startup
service mobicore /system/bin/mcDriverDaemon -r /system/vendor/secapp/020a0000000000000000000000000000.drbin
setenv MC_REGISTRY_PATH /system/vendor/secapp
user drmrpc
group drmrpc
class main
# on userdebug and eng builds, enable kgdb on the serial console
on property:ro.debuggable=1
write /sys/module/kgdboc/parameters/kgdboc ttyFIQ2
write /sys/module/fiq_debugger/parameters/kgdb_enable 1
# bugreport is triggered by holding down volume down, volume up and power
service bugreport /system/bin/bugmailer.sh -v
class main
disabled
oneshot
keycodes 114 115 116