Home | History | Annotate | Download | only in etc
      1 import /init.recovery.${ro.hardware}.rc
      2 
      3 on early-init
      4     start ueventd
      5     start healthd
      6 
      7 on init
      8     export PATH /sbin
      9     export ANDROID_ROOT /system
     10     export ANDROID_DATA /data
     11     export EXTERNAL_STORAGE /sdcard
     12 
     13     symlink /system/etc /etc
     14 
     15     mkdir /sdcard
     16     mkdir /system
     17     mkdir /data
     18     mkdir /cache
     19     mount /tmp /tmp tmpfs
     20 
     21     chown root shell /tmp
     22     chmod 0775 /tmp
     23 
     24     write /sys/class/android_usb/android0/enable 0
     25     write /sys/class/android_usb/android0/idVendor 18D1
     26     write /sys/class/android_usb/android0/idProduct D001
     27     write /sys/class/android_usb/android0/functions adb
     28     write /sys/class/android_usb/android0/iManufacturer ${ro.product.manufacturer}
     29     write /sys/class/android_usb/android0/iProduct ${ro.product.model}
     30     write /sys/class/android_usb/android0/iSerial ${ro.serialno}
     31 
     32 
     33 on boot
     34 
     35     ifup lo
     36     hostname localhost
     37     domainname localdomain
     38 
     39     class_start default
     40 
     41 on property:sys.powerctl=*
     42    powerctl ${sys.powerctl}
     43 
     44 service ueventd /sbin/ueventd
     45     critical
     46 
     47 service healthd /sbin/healthd -n
     48     critical
     49 
     50 service recovery /sbin/recovery
     51 
     52 service adbd /sbin/adbd recovery
     53     disabled
     54     socket adbd stream 660 system system
     55 
     56 # Always start adbd on userdebug and eng builds
     57 on property:ro.debuggable=1
     58     write /sys/class/android_usb/android0/enable 1
     59     start adbd
     60 
     61 # Restart adbd so it can run as root
     62 on property:service.adb.root=1
     63     write /sys/class/android_usb/android0/enable 0
     64     restart adbd
     65     write /sys/class/android_usb/android0/enable 1
     66