blob: 554d4e634cf6ef52cb6124374e333a2e346525fe [file] [log] [blame]
Colin Crossdd6a0412010-05-14 13:42:20 -07001on early-init
2 start ueventd
The Android Open Source Projectc24a8e62009-03-03 19:28:42 -08003
4on init
5 export PATH /sbin
6 export ANDROID_ROOT /system
7 export ANDROID_DATA /data
8 export EXTERNAL_STORAGE /sdcard
9
10 symlink /system/etc /etc
11
12 mkdir /sdcard
13 mkdir /system
14 mkdir /data
15 mkdir /cache
16 mount /tmp /tmp tmpfs
17
18on boot
19
20 ifup lo
21 hostname localhost
22 domainname localdomain
23
24 class_start default
25
Colin Crossdd6a0412010-05-14 13:42:20 -070026service ueventd /sbin/ueventd
27 critical
The Android Open Source Projectc24a8e62009-03-03 19:28:42 -080028
29service recovery /sbin/recovery
30
31service adbd /sbin/adbd recovery
Kenny Rootecc76ba2010-06-28 09:01:22 -070032 disabled
The Android Open Source Projectc24a8e62009-03-03 19:28:42 -080033
Mike Lockwood718a2f72011-06-29 10:22:04 -040034# Always start adbd on userdebug and eng builds
35on property:ro.debuggable=1
Mike Lockwood7e58b652011-06-19 02:52:01 -040036 write /sys/class/android_usb/android0/enable 0
Mike Lockwood718a2f72011-06-29 10:22:04 -040037 write /sys/class/android_usb/android0/idVendor 18D1
38 write /sys/class/android_usb/android0/idProduct D001
39 write /sys/class/android_usb/android0/functions adb
Mike Lockwood7e58b652011-06-19 02:52:01 -040040 write /sys/class/android_usb/android0/enable 1
Michael Ward93348782011-07-07 13:21:24 -070041 write /sys/class/android_usb/android0/iManufacturer $ro.product.manufacturer
42 write /sys/class/android_usb/android0/iProduct $ro.product.model
43 write /sys/class/android_usb/android0/iSerial $ro.serialno
The Android Open Source Projectc24a8e62009-03-03 19:28:42 -080044 start adbd
45
Mike Lockwood718a2f72011-06-29 10:22:04 -040046# Restart adbd so it can run as root
Doug Zongkerfb04b872011-06-23 15:30:34 -070047on property:service.adb.root=1
48 write /sys/class/android_usb/android0/enable 0
49 restart adbd
50 write /sys/class/android_usb/android0/enable 1