Colin Cross | dd6a041 | 2010-05-14 13:42:20 -0700 | [diff] [blame] | 1 | on early-init |
| 2 | start ueventd |
The Android Open Source Project | c24a8e6 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 3 | |
| 4 | on 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 | |
Doug Zongker | 703ed15 | 2012-03-19 15:52:03 -0700 | [diff] [blame] | 18 | chown root shell /tmp |
| 19 | chmod 0775 /tmp |
| 20 | |
Doug Zongker | 6639248 | 2012-01-10 12:16:04 -0800 | [diff] [blame] | 21 | write /sys/class/android_usb/android0/enable 0 |
| 22 | write /sys/class/android_usb/android0/idVendor 18D1 |
| 23 | write /sys/class/android_usb/android0/idProduct D001 |
| 24 | write /sys/class/android_usb/android0/functions adb |
| 25 | write /sys/class/android_usb/android0/iManufacturer ${ro.product.manufacturer} |
| 26 | write /sys/class/android_usb/android0/iProduct ${ro.product.model} |
| 27 | write /sys/class/android_usb/android0/iSerial ${ro.serialno} |
| 28 | |
| 29 | |
The Android Open Source Project | c24a8e6 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 30 | on boot |
| 31 | |
| 32 | ifup lo |
| 33 | hostname localhost |
| 34 | domainname localdomain |
| 35 | |
| 36 | class_start default |
| 37 | |
Colin Cross | dd6a041 | 2010-05-14 13:42:20 -0700 | [diff] [blame] | 38 | service ueventd /sbin/ueventd |
| 39 | critical |
The Android Open Source Project | c24a8e6 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 40 | |
| 41 | service recovery /sbin/recovery |
| 42 | |
| 43 | service adbd /sbin/adbd recovery |
Kenny Root | ecc76ba | 2010-06-28 09:01:22 -0700 | [diff] [blame] | 44 | disabled |
The Android Open Source Project | c24a8e6 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 45 | |
Mike Lockwood | 718a2f7 | 2011-06-29 10:22:04 -0400 | [diff] [blame] | 46 | # Always start adbd on userdebug and eng builds |
| 47 | on property:ro.debuggable=1 |
Mike Lockwood | 7e58b65 | 2011-06-19 02:52:01 -0400 | [diff] [blame] | 48 | write /sys/class/android_usb/android0/enable 1 |
The Android Open Source Project | c24a8e6 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 49 | start adbd |
| 50 | |
Mike Lockwood | 718a2f7 | 2011-06-29 10:22:04 -0400 | [diff] [blame] | 51 | # Restart adbd so it can run as root |
Doug Zongker | fb04b87 | 2011-06-23 15:30:34 -0700 | [diff] [blame] | 52 | on property:service.adb.root=1 |
| 53 | write /sys/class/android_usb/android0/enable 0 |
| 54 | restart adbd |
| 55 | write /sys/class/android_usb/android0/enable 1 |