PageRenderTime 55ms CodeModel.GetById 51ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/init.blade.rc

http://github.com/CyanogenMod/android_device_zte_blade
Unknown | 135 lines | 109 code | 26 blank | 0 comment | 0 complexity | 52918980f0b784f8eae39420171d3dcc MD5 | raw file
  1
  2service dhcp-service /system/bin/netcfg wlan0 dhcp
  3        oneshot
  4
  5on property:dev.bootcomplete=1
  6        stop dhcp-service
  7        start dhcp-service
  8
  9on boot
 10
 11# cpufreq configurations
 12#    write /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq 245760
 13#    write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor ondemand
 14    write /sys/devices/system/cpu/cpufreq/ondemand/sampling_rate 500000
 15    write /sys/devices/system/cpu/cpufreq/ondemand/up_threshold 90
 16    write /sys/devices/system/cpu/cpufreq/ondemand/down_threshold 30
 17
 18# Setup charging
 19    chown system system /sys/module/msm_battery/parameters/usb_chg_enable
 20
 21# Setup bluetooth
 22    chown bluetooth bluetooth /sys/module/bluetooth_power/parameters/power
 23    chown bluetooth bluetooth /sys/class/rfkill/rfkill0/type
 24    chown bluetooth bluetooth /sys/class/rfkill/rfkill0/state
 25    chown bluetooth bluetooth /proc/bluetooth/sleep/proto
 26    chown system system /sys/module/sco/parameters/disable_esco
 27    chmod 0660 /sys/module/bluetooth_power/parameters/power
 28    chmod 0660 /sys/class/rfkill/rfkill0/state
 29    chmod 0660 /proc/bluetooth/sleep/proto
 30    chown bluetooth bluetooth /sys/devices/platform/msm_serial_hs.0/clock
 31    chmod 0660 /sys/devices/platform/msm_serial_hs.0/clock
 32
 33# Setup android gadget
 34   write /sys/module/g_android/parameters/serial_number CM7-Blade
 35   write /sys/module/g_android/parameters/product_id 0x1351
 36
 37#create  WIFI filesystem structure
 38    mkdir /data/misc 01771 system misc
 39    mkdir /data/misc/wifi 0770 system wifi
 40    mkdir /data/misc/wifi/sockets
 41    chown system wifi /data/misc/wifi/sockets
 42    chmod 770 /data/misc/wifi/sockets
 43    mkdir /data/misc/dhcp 0770 dhcp dhcp
 44    chown dhcp dhcp /data/misc/dhcp
 45    mkdir /data/system 0775 system system
 46
 47   mkdir /data/local
 48   chmod 0777 /data/local
 49   chown radio shell /data/local
 50   mkdir /data/local/tmp
 51   chmod 0777 /data/local/tmp
 52   chown radio shell /data/local/tmp
 53
 54# For qmuxd socket
 55    mkdir /data/radio 0770 radio radio
 56    chown radio radio 0770 /data/radio
 57
 58    chown system system /sys/class/leds/green/blink
 59    chown system system /sys/class/leds/green/brightness
 60    chown system system /sys/class/leds/green/grpfreq
 61    chown system system /sys/class/leds/green/grppwm
 62    chown system system /sys/class/leds/red/blink
 63    chown system system /sys/class/leds/red/brightness
 64    chown system system /sys/class/leds/red/grpfreq
 65    chown system system /sys/class/leds/red/grppwm
 66    chown system system /sys/class/leds/amber/blink
 67    chown system system /sys/class/leds/amber/brightness
 68    chown system system /sys/class/leds/amber/grpfreq
 69    chown system system /sys/class/leds/amber/grppwm
 70
 71# SD card polling
 72    chown system system /sys/module/g_android/parameters/product_id
 73    chown system system /sys/devices/platform/msm_sdcc.1/polling
 74    chown system system /sys/devices/platform/msm_sdcc.2/polling
 75    chown system system /sys/devices/platform/msm_sdcc.3/polling
 76    chown system system /sys/devices/platform/msm_sdcc.4/polling
 77    chown system system /sys/devices/platform/android_usb/composition
 78    chown system system /sys/devices/platform/android_usb/remote_wakeup
 79
 80
 81# Enable MASS storage on SDCARD
 82    write /sys/devices/platform/mass_storage/lun0/file /dev/block/mmcblk0p1
 83    write /sys/bus/platform/drivers/msm_sdcc/msm_sdcc.1/polling 1
 84
 85service qmuxd /system/bin/qmuxd 
 86
 87on property:init.svc.bluetoothd=running
 88    write /sys/devices/virtual/bluetooth/hci0/idle_timeout 7000
 89    start abtfilt
 90
 91on property:init.svc.bluetoothd=stopped
 92    stop abtfilt
 93
 94service hci_qcomm_init /system/bin/log -t qcom-bluetooth -p i "hci_qcomm_init service requested"
 95    user bluetooth
 96    group bluetooth net_bt_admin
 97    disabled
 98    oneshot
 99
100service hciattach /system/bin/sh /system/etc/init.bt.sh
101    user bluetooth
102    group qcom_oncrpc bluetooth net_bt_admin system
103    disabled
104    oneshot
105
106on property:init.svc.wpa_supplicant=stopped
107    stop dhcpcd_wlan0
108
109# WPA SETTINGS
110service wpa_supplicant /system/bin/wpa_supplicant -Dawext -iwlan0 -W -c/data/misc/wifi/wpa_supplicant.conf
111    group wifi inet
112    socket wpa_wlan0 dgram 660 wifi wifi
113    disabled
114    oneshot
115
116service dhcpcd_wlan0 /system/bin/dhcpcd -BKL
117    disabled
118    oneshot
119
120#service wlan_tool /system/bin/wlan_tool
121#        disabled
122#        oneshot
123
124service abtfilt /system/bin/abtfilt -c -d -z -n
125    disabled
126    oneshot
127
128service akmd /system/bin/akmd2
129    oneshot
130
131service hostapd /system/bin/hostapd /data/misc/wifi/hostapd.conf
132    socket hostapd_athap0 dgram 660 wifi wifi
133    group wifi inet
134    oneshot
135    disabled