Amit Pundir | 4e37582 | 2019-04-18 16:46:10 +0530 | [diff] [blame] | 1 | import init.${ro.hardware}.usb.rc |
| 2 | import init.${ro.hardware}.power.rc |
| 3 | |
| 4 | on fs |
Yongqin Liu | bbb804e | 2020-04-21 17:52:44 +0800 | [diff] [blame] | 5 | mount_all /vendor/etc/fstab.${ro.hardware} |
| 6 | swapon_all /vendor/etc/fstab.${ro.hardware} |
Amit Pundir | 4e37582 | 2019-04-18 16:46:10 +0530 | [diff] [blame] | 7 | |
Yongqin Liu | ab5d0cc | 2020-03-20 13:44:54 +0800 | [diff] [blame] | 8 | on post-fs |
| 9 | # set RLIMIT_MEMLOCK to 64MB |
| 10 | setrlimit 8 67108864 67108864 |
| 11 | |
Amit Pundir | 4e37582 | 2019-04-18 16:46:10 +0530 | [diff] [blame] | 12 | on init |
| 13 | # For legacy support |
| 14 | # See storage config details at http://source.android.com/tech/storage/ |
| 15 | # since /storage is mounted on post-fs in init.rc |
| 16 | symlink /sdcard /storage/sdcard0 |
| 17 | |
| 18 | # Initialize cpusets to boot-time values |
| 19 | write /dev/cpuset/foreground/cpus 0-7 |
| 20 | write /dev/cpuset/background/cpus 0-7 |
| 21 | write /dev/cpuset/system-background/cpus 0-7 |
| 22 | write /dev/cpuset/top-app/cpus 0-7 |
| 23 | |
| 24 | on early-boot |
| 25 | mount debugfs debugfs /sys/kernel/debug |
| 26 | chmod 755 /sys/kernel/debug |
| 27 | chmod 755 /sys/kernel/debug/sync |
| 28 | chown graphics graphics /sys/kernel/debug/sync/sw_sync |
| 29 | chmod 777 /sys/kernel/debug/sync/sw_sync |
| 30 | chown graphics graphics /sys/kernel/debug/sync/info |
| 31 | |
| 32 | on zygote-start |
| 33 | mkdir /data/vendor/wifi 0770 wifi wifi |
| 34 | mkdir /data/vendor/wifi/wpa 0770 wifi wifi |
| 35 | mkdir /data/vendor/wifi/wpa/sockets 0770 wifi wifi |
| 36 | |
| 37 | on property:sys.boot_completed=1 |
Amit Pundir | 66c35f4 | 2020-06-21 21:50:34 +0530 | [diff] [blame] | 38 | chmod 0755 /sys/kernel/debug/tracing |
| 39 | |
Amit Pundir | 4e37582 | 2019-04-18 16:46:10 +0530 | [diff] [blame] | 40 | # update cpuset now that processors are up |
| 41 | # Foreground should contain most cores (7 is reserved for top-app) |
| 42 | write /dev/cpuset/foreground/cpus 0-6 |
| 43 | |
| 44 | # top-app gets all cpus (including reserved #7) |
| 45 | write /dev/cpuset/top-app/cpus 0-7 |
| 46 | |
| 47 | #background contains a small subset (generally one little core) |
| 48 | write /dev/cpuset/background/cpus 0 |
| 49 | |
| 50 | # add system-background cpuset, a new cpuset for system services |
| 51 | # that should not run on larger cores |
| 52 | # system-background is for system tasks that should only run on |
| 53 | # little cores, not on bigs to be used only by init |
| 54 | write /dev/cpuset/system-background/cpus 0-3 |
| 55 | |
| 56 | service wpa_supplicant /vendor/bin/hw/wpa_supplicant \ |
| 57 | -Dnl80211 -g@android:wpa_wlan0 |
| 58 | interface android.hardware.wifi.supplicant@1.0::ISupplicant default |
| 59 | interface android.hardware.wifi.supplicant@1.1::ISupplicant default |
| 60 | socket wpa_wlan0 dgram 660 wifi wifi |
| 61 | class main |
| 62 | disabled |
| 63 | oneshot |