OSDN Git Service

Add support of OpenGApps
[android-x86/device-generic-common.git] / init.x86.rc
1 import /init.superuser.rc
2
3 on early-init
4     write /proc/sys/kernel/ctrl-alt-del 1
5
6     write /sys/module/xt_qtaguid/parameters/ctrl_write_limited N
7
8     export force_s3tc_enable true
9     export EGL_LOG_LEVEL info
10 #   export EGL_DRIVERS egl_dri2
11
12 on init
13
14 on fs
15     mount_all /fstab.${ro.hardware}
16
17 on post-fs
18     exec u:r:init:s0 -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh
19
20 on post-fs-data
21     mkdir /data/misc/wifi 0770 wifi wifi
22     mkdir /data/misc/wifi/sockets 0770 wifi wifi
23     mkdir /data/misc/wifi/wpa_supplicant 0770 wifi wifi
24     mkdir /data/misc/dhcp 0770 dhcp dhcp
25     mkdir /data/system 0775 system system
26     chown wifi wifi /data/misc/wifi/wpa_supplicant.conf
27
28     # Set indication (checked by vold) that we have finished this action
29     setprop vold.post_fs_data_done 1
30
31 on boot
32     setprop ro.radio.use-ppp yes
33     setprop status.battery.state Slow
34     setprop status.battery.level 5
35     setprop status.battery.level_raw  50
36     setprop status.battery.level_scale 9
37
38     # merge from system.prop
39     setprop ro.config.sync yes
40     setprop app.setupwizard.disable 0
41     setprop ro.alarm.volume.adjustable true
42     setprop ro.simulated.phone false
43     # disable red frame boarder in eng build
44     setprop persist.sys.strictmode.visual 0
45     setprop persist.sys.strictmode.disable 1
46     # workaround for h.265 slowness
47     setprop sys.media.vdec.drop 0
48
49 service wpa_supplicant /system/bin/wpa_supplicant -c/data/misc/wifi/wpa_supplicant.conf \
50     -iwlan0 -Dnl80211 \
51     -O/data/misc/wifi/sockets \
52     -e/data/misc/wifi/entropy.bin -g@android:wpa_wlan0
53     #   we will start as root and wpa_supplicant will switch to user wifi
54     #   after setting up the capabilities required for WEXT
55     #   user wifi
56     #   group wifi inet keystore
57     class main
58     socket wpa_wlan0 dgram 660 wifi wifi
59     disabled
60
61 service nativebridge /system/bin/enable_nativebridge
62     class main
63     disabled
64     oneshot
65     seclabel u:r:zygote:s0
66
67 service logcat /system/bin/logcat -b all -v threadtime -f /data/log.txt
68     class debug
69
70 service btattach /system/bin/btattach
71     class main
72     disabled
73     oneshot
74     seclabel u:r:bluetooth:s0
75
76 service rtk_hciattach /vendor/bin/rtk_hciattach -n -s 115200 /dev/rtk_h5 rtk_h5
77     class main
78     disabled
79     oneshot
80     seclabel u:r:bluetooth:s0
81
82 service wacom-input /system/bin/wacom-input
83     disabled
84     oneshot
85     seclabel u:r:inputflinger:s0
86
87 service tablet-mode /system/bin/tablet-mode
88     disabled
89     oneshot
90     seclabel u:r:inputflinger:s0
91
92 service ctrl-alt-del /system/bin/input keyevent --longpress POWER
93     disabled
94     oneshot
95     keycodes 97 100 111
96     seclabel u:r:init:s0
97
98 on property:system_init.startsurfaceflinger=0
99     # disable cursor blinking
100     write /dev/tty0 "\e[?17;0;0c"
101     start surfaceflinger
102     stop console
103
104 on property:sys.boot_completed=1
105     write /proc/sys/kernel/ctrl-alt-del 0
106     exec u:r:init:s0 -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh bootcomplete
107
108 on property:net.dns1=*
109     exec u:r:init:s0 -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh netconsole
110
111 on property:debug.logcat=1
112     class_start debug
113
114 on property:persist.sys.nativebridge=1
115     start nativebridge
116
117 on property:persist.sys.nativebridge=0
118     stop nativebridge