Rohit R Sekhar | adf4971 | 2022-11-17 21:05:16 +0530 | [diff] [blame] | 1 | # Copyright (c) 2009-2012, 2014-2020, The Linux Foundation. All rights reserved. |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 2 | # |
| 3 | # Redistribution and use in source and binary forms, with or without |
| 4 | # modification, are permitted provided that the following conditions are met: |
| 5 | # * Redistributions of source code must retain the above copyright |
| 6 | # notice, this list of conditions and the following disclaimer. |
| 7 | # * Redistributions in binary form must reproduce the above copyright |
| 8 | # notice, this list of conditions and the following disclaimer in the |
| 9 | # documentation and/or other materials provided with the distribution. |
| 10 | # * Neither the name of The Linux Foundation nor |
| 11 | # the names of its contributors may be used to endorse or promote |
| 12 | # products derived from this software without specific prior written |
| 13 | # permission. |
| 14 | # |
| 15 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
| 16 | # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
| 17 | # IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
| 18 | # NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR |
| 19 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, |
| 20 | # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
| 21 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; |
| 22 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, |
| 23 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR |
| 24 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF |
| 25 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 26 | # |
Michael Bestas | 26f3c9d | 2024-07-16 13:45:52 -0400 | [diff] [blame] | 27 | # Changes from Qualcomm Innovation Center are provided under the following license: |
| 28 | # Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved. |
| 29 | # SPDX-License-Identifier: BSD-3-Clause-Clear |
| 30 | # |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 31 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 32 | import /vendor/etc/init/hw/init.qcom.usb.rc |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 33 | import /vendor/etc/init/hw/init.target.rc |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 34 | |
| 35 | on early-init |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 36 | # create symlink for vendor mount points |
| 37 | symlink /vendor/firmware_mnt /firmware |
| 38 | symlink /vendor/bt_firmware /bt_firmware |
| 39 | symlink /vendor/dsp /dsp |
| 40 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 41 | # Change ownership of sysfs power control node |
| 42 | chown system graphics /sys/class/drm/card0/device/power/control |
| 43 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 44 | #Disable UFS clock scaling |
| 45 | write /sys/bus/platform/devices/1d84000.ufshc/clkscale_enable 0 |
| 46 | |
| 47 | chown root system /dev/kmsg |
| 48 | chmod 0620 /dev/kmsg |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 49 | |
| 50 | on init |
| 51 | |
| 52 | # Support legacy paths |
| 53 | symlink /sdcard /mnt/sdcard |
| 54 | symlink /sdcard /storage/sdcard0 |
| 55 | |
| 56 | # Create cgroup mount point for memory |
| 57 | mkdir /sys/fs/cgroup/memory/bg 0750 root system |
| 58 | write /sys/fs/cgroup/memory/bg/memory.swappiness 140 |
| 59 | write /sys/fs/cgroup/memory/bg/memory.move_charge_at_immigrate 1 |
| 60 | chown root system /sys/fs/cgroup/memory/bg/tasks |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 61 | chmod 0660 /sys/fs/cgroup/memory/bg/tasks |
| 62 | |
Michael Bestas | 9bb5a14 | 2024-05-29 00:19:57 +0300 | [diff] [blame] | 63 | # Support mount point for vibrator |
| 64 | chown system system /sys/class/leds/drv26xx_haptic/activate |
| 65 | chown system system /sys/class/leds/drv26xx_haptic/duration |
| 66 | chown system system /sys/class/leds/drv26xx_haptic/state |
| 67 | chown system system /sys/class/leds/drv26xx_haptic/calib |
| 68 | chown system system /sys/class/leds/drv26xx_haptic/CalBemf |
| 69 | chown system system /sys/class/leds/drv26xx_haptic/CalComp |
| 70 | chown system system /sys/class/leds/drv26xx_haptic/CalGain |
| 71 | chown system system /sys/class/leds/drv26xx_haptic/calib |
| 72 | chown system system /sys/class/leds/drv26xx_haptic/diag |
| 73 | chown system system /sys/class/leds/drv26xx_haptic/f0_lsb |
| 74 | chown system system /sys/class/leds/drv26xx_haptic/f0_msb |
| 75 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 76 | on early-boot |
| 77 | # set RLIMIT_MEMLOCK to 64MB |
| 78 | setrlimit 8 67108864 67108864 |
| 79 | # Allow subsystem (modem etc) debugging |
| 80 | write /sys/kernel/boot_adsp/boot 1 |
| 81 | write /sys/kernel/boot_cdsp/boot 1 |
| 82 | write /sys/devices/virtual/npu/msm_npu/boot 1 |
| 83 | write /sys/devices/virtual/cvp/cvp/boot 1 |
| 84 | exec u:r:vendor_qti_init_shell:s0 -- /vendor/bin/init.qcom.early_boot.sh |
| 85 | exec u:r:vendor_qti_init_shell:s0 -- /vendor/bin/init.qti.can.sh |
| 86 | setprop ro.sf.lcd_density ${vendor.display.lcd_density} |
| 87 | |
LuK1337 | 7a209f6 | 2019-07-11 15:32:52 +0200 | [diff] [blame] | 88 | # SSR |
| 89 | write /sys/bus/msm_subsys/devices/subsys0/restart_level RELATED |
| 90 | write /sys/bus/msm_subsys/devices/subsys1/restart_level RELATED |
| 91 | write /sys/bus/msm_subsys/devices/subsys2/restart_level RELATED |
| 92 | write /sys/bus/msm_subsys/devices/subsys3/restart_level RELATED |
| 93 | write /sys/bus/msm_subsys/devices/subsys4/restart_level RELATED |
| 94 | write /sys/bus/msm_subsys/devices/subsys5/restart_level RELATED |
| 95 | write /sys/bus/msm_subsys/devices/subsys6/restart_level RELATED |
| 96 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 97 | chown system system /mnt/vendor/persist/data/pfm/licenses |
| 98 | chmod 0775 /mnt/vendor/persist/data/pfm/licenses |
| 99 | chown system system /mnt/vendor/persist/data/pfm/licenses/store_0 |
| 100 | chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_0 |
| 101 | chown system system /mnt/vendor/persist/data/pfm/licenses/store_1 |
| 102 | chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_1 |
| 103 | chown system system /mnt/vendor/persist/data/pfm/licenses/store_2 |
| 104 | chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_2 |
| 105 | chown system system /mnt/vendor/persist/data/pfm/licenses/store_3 |
| 106 | chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_3 |
| 107 | chown system system /mnt/vendor/persist/data/pfm/licenses/store_4 |
| 108 | chmod 0664 /mnt/vendor/persist/data/pfm/licenses/store_4 |
| 109 | |
| 110 | on boot |
| 111 | chown bluetooth bluetooth /sys/module/bluetooth_power/parameters/power |
| 112 | chown bluetooth net_bt /sys/class/rfkill/rfkill0/type |
| 113 | chown bluetooth net_bt /sys/class/rfkill/rfkill0/state |
| 114 | chown bluetooth bluetooth /proc/bluetooth/sleep/proto |
| 115 | chown bluetooth bluetooth /sys/module/hci_uart/parameters/ath_lpm |
| 116 | chown bluetooth bluetooth /sys/module/hci_uart/parameters/ath_btwrite |
| 117 | chown system system /sys/module/sco/parameters/disable_esco |
| 118 | chown bluetooth bluetooth /sys/module/hci_smd/parameters/hcismd_set |
| 119 | chown system system /sys/module/msm_core/parameters/polling_interval |
| 120 | chown system system /sys/module/msm_core/parameters/disabled |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 121 | chown system system /sys/kernel/boot_slpi/ssr |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 122 | chmod 0660 /sys/module/bluetooth_power/parameters/power |
| 123 | chmod 0660 /sys/module/hci_smd/parameters/hcismd_set |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 124 | chmod 0660 /sys/class/rfkill/rfkill0/state |
| 125 | chmod 0660 /proc/bluetooth/sleep/proto |
| 126 | chown bluetooth net_bt /dev/ttyHS0 |
| 127 | chmod 0660 /sys/module/hci_uart/parameters/ath_lpm |
| 128 | chmod 0660 /sys/module/hci_uart/parameters/ath_btwrite |
| 129 | chmod 0660 /dev/ttyHS0 |
| 130 | chown bluetooth bluetooth /sys/devices/platform/msm_serial_hs.0/clock |
| 131 | chmod 0660 /sys/devices/platform/msm_serial_hs.0/clock |
| 132 | |
| 133 | chmod 0660 /dev/ttyHS2 |
| 134 | chown bluetooth bluetooth /dev/ttyHS2 |
| 135 | |
| 136 | chown bluetooth net_bt /sys/class/rfkill/rfkill0/device/extldo |
| 137 | chmod 0660 /sys/class/rfkill/rfkill0/device/extldo |
| 138 | |
| 139 | # This location is used by QCRIL to host UNIX domain |
| 140 | # socket files used for internal IPC within QCRIL |
| 141 | # modules |
| 142 | mkdir /dev/socket/qmux_radio 0770 radio radio |
| 143 | chmod 2770 /dev/socket/qmux_radio |
| 144 | |
| 145 | mkdir /persist/drm 0770 system system |
| 146 | mkdir /persist/bluetooth 0770 bluetooth bluetooth |
| 147 | mkdir /persist/misc 0770 system system |
| 148 | mkdir /persist/alarm 0770 system system |
| 149 | mkdir /mnt/vendor/persist/time 0770 system system |
| 150 | mkdir /mnt/vendor/persist/secnvm 0770 system system |
| 151 | mkdir /mnt/vendor/persist/iar_db 0770 system system |
| 152 | mkdir /mnt/vendor/spunvm 0770 system system |
| 153 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 154 | setprop wifi.interface wlan0 |
| 155 | |
| 156 | setprop ro.telephony.call_ring.multiple false |
| 157 | |
| 158 | #Remove SUID bit for iproute2 ip tool |
| 159 | chmod 0755 /system/bin/ip |
| 160 | |
| 161 | |
| 162 | chmod 0444 /sys/devices/platform/msm_hsusb/gadget/usb_state |
| 163 | |
| 164 | setprop net.tcp.2g_init_rwnd 10 |
| 165 | |
| 166 | # To prevent out of order acknowledgements from making |
| 167 | # connection tracking to treat them as not belonging to |
| 168 | # the connection they belong to. |
| 169 | # Otherwise, a weird issue happens in which some long |
| 170 | # connections on high-throughput links get dropped when |
| 171 | # an ack packet comes out of order |
| 172 | write /proc/sys/net/netfilter/nf_conntrack_tcp_be_liberal 1 |
| 173 | |
| 174 | # Set the console loglevel to < KERN_WARN |
| 175 | # Set the default message loglevel to KERN_INFO |
| 176 | write /proc/sys/kernel/printk "4 6 1 7" |
| 177 | |
| 178 | # Allow access for CCID command/response timeout configuration |
| 179 | chown system system /sys/module/ccid_bridge/parameters/bulk_msg_timeout |
| 180 | |
| 181 | # bond0 used by FST Manager |
| 182 | chown wifi wifi /sys/class/net/bond0/bonding/queue_id |
| 183 | |
Nagireddy Annem | 0126855 | 2022-02-24 16:57:25 +0530 | [diff] [blame] | 184 | # Allow access to emmc dload sysfs node |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 185 | chown root system /sys/kernel/dload/emmc_dload |
| 186 | chmod 0660 /sys/kernel/dload/emmc_dload |
| 187 | chown root system /dev/block/bootdevice/by-name/ramdump |
| 188 | chmod 0660 /dev/block/bootdevice/by-name/ramdump |
| 189 | chown root system /sys/kernel/dload/dload_mode |
| 190 | chmod 0660 /sys/kernel/dload/dload_mode |
| 191 | |
Michael Bestas | 9bb5a14 | 2024-05-29 00:19:57 +0300 | [diff] [blame] | 192 | chmod 0660 /sys/class/display/panel/bl_fps_func |
| 193 | chown system system /sys/class/display/panel/bl_fps_func |
| 194 | chmod 0660 /sys/class/backlight/panel0-backlight/brightness |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 195 | chown system system /sys/class/backlight/panel0-backlight/brightness |
| 196 | chown system system /sys/class/backlight/panel0-backlight/max_brightness |
| 197 | chown system system /sys/class/backlight/panel1-backlight/brightness |
| 198 | chown system system /sys/class/backlight/panel1-backlight/max_brightness |
| 199 | |
| 200 | # Allow access to sensors device attributes |
| 201 | chown system system /sys/class/sensors/MPU6050-accel/enable |
| 202 | chown system system /sys/class/sensors/MPU6050-accel/poll_delay |
| 203 | chown system system /sys/class/sensors/MPU6050-gyro/enable |
| 204 | chown system system /sys/class/sensors/MPU6050-gyro/poll_delay |
| 205 | chown system system /sys/class/sensors/apds9930-light/enable |
| 206 | chown system system /sys/class/sensors/apds9930-light/poll_delay |
| 207 | chown system system /sys/class/sensors/apds9930-proximity/enable |
| 208 | chown system system /sys/class/sensors/apds9930-proximity/poll_delay |
| 209 | |
| 210 | # Create directory used for display |
| 211 | # for backward compatibility |
| 212 | mkdir /persist/display 0770 system graphics |
| 213 | mkdir /mnt/vendor/persist/display 0770 system graphics |
| 214 | |
| 215 | # Create vpp directory |
| 216 | mkdir /mnt/vendor/persist/vpp 0770 media media |
| 217 | |
Michael Bestas | 9bb5a14 | 2024-05-29 00:19:57 +0300 | [diff] [blame] | 218 | chown system system /dev/goodix_fp |
| 219 | chmod 0660 /dev/goodix_fp |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 220 | |
| 221 | # Create hvdcp_opti directory |
| 222 | mkdir /mnt/vendor/persist/hvdcp_opti 0770 root system |
| 223 | |
| 224 | # limit discard size to 128MB in order to avoid long IO latency |
| 225 | write /sys/block/sda/queue/discard_max_bytes 134217728 |
| 226 | |
| 227 | # msm specific files that need to be created on /data |
| 228 | on post-fs-data |
| 229 | mkdir /data/vendor/misc 01771 system system |
| 230 | |
| 231 | # Create directory used for dump collection |
| 232 | mkdir /data/vendor/ssrdump 0770 root system |
| 233 | |
| 234 | # Create directory used by display clients |
| 235 | mkdir /data/vendor/display 0770 system graphics |
| 236 | |
| 237 | # Change lm related dirs |
| 238 | mkdir /data/vendor/lm 0700 root root |
| 239 | |
| 240 | # Create directory used by powermodule |
| 241 | mkdir /data/vendor/pwr 0700 root root |
| 242 | |
| 243 | # Create directory used by media clients |
| 244 | mkdir /data/vendor/media 0770 mediacodec media |
| 245 | |
| 246 | # Create /data/vendor/tzstorage directory for SFS listener |
| 247 | mkdir /data/vendor/tzstorage 0770 system system |
| 248 | |
| 249 | # Create directory for apps access via QTEEConnector |
| 250 | mkdir /data/vendor/qtee 0770 system system |
| 251 | |
| 252 | #Create folder of camera |
| 253 | mkdir /data/vendor/camera 0770 camera camera |
| 254 | |
| 255 | |
| 256 | #Create directory for tftp |
| 257 | mkdir /data/vendor/tombstones 0771 system system |
| 258 | mkdir /data/vendor/tombstones/rfs 0771 system system |
| 259 | |
| 260 | mkdir /data/vendor/ramdump 0771 root system |
| 261 | mkdir /data/vendor/bluetooth 0770 bluetooth bluetooth |
| 262 | mkdir /data/vendor/ramdump/bluetooth 0770 bluetooth bluetooth |
| 263 | |
| 264 | # Create the directories used by the Wireless subsystem |
| 265 | mkdir /data/vendor/wifi 0770 wifi wifi |
| 266 | mkdir /data/vendor/wifi/sockets 0770 wifi wifi |
| 267 | mkdir /data/vendor/wifi/hostapd 0770 wifi wifi |
| 268 | mkdir /data/vendor/wifi/hostapd/ctrl 0770 wifi wifi |
| 269 | mkdir /data/vendor/wifi/wpa_supplicant 0770 wifi wifi |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 270 | mkdir /data/vendor/wifi/wpa 0770 wifi wifi |
| 271 | mkdir /data/vendor/wifi/wpa/sockets 0770 wifi wifi |
| 272 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 273 | # Create the directories used by CnE subsystem |
| 274 | mkdir /data/vendor/connectivity 0771 radio radio |
| 275 | chown radio radio /data/vendor/connectivity |
| 276 | |
| 277 | # Create directory used by audio subsystem |
| 278 | mkdir /data/vendor/audio 0770 audio audio |
| 279 | |
| 280 | # Create directory for audio delta files |
| 281 | mkdir /data/vendor/audio/acdbdata 0770 media audio |
| 282 | mkdir /data/vendor/audio/acdbdata/delta 0770 media audio |
| 283 | |
| 284 | # Create directory for radio |
| 285 | mkdir /data/vendor/radio 0770 system radio |
| 286 | rm /data/vendor/radio/shmbus |
| 287 | |
| 288 | # Create directory for modem_config |
| 289 | mkdir /data/vendor/modem_config 0570 radio root |
| 290 | |
| 291 | # Mounting of persist is moved to 'on emmc-fs' and 'on fs' sections |
| 292 | # We chown/chmod /persist again so because mount is run as root + defaults |
| 293 | chown root system /persist |
| 294 | chmod 0771 /persist |
| 295 | chown system system /persist/WCNSS_qcom_wlan_nv.bin |
| 296 | chmod 0664 /sys/devices/platform/msm_sdcc.1/polling |
| 297 | chmod 0664 /sys/devices/platform/msm_sdcc.2/polling |
| 298 | chmod 0664 /sys/devices/platform/msm_sdcc.3/polling |
| 299 | chmod 0664 /sys/devices/platform/msm_sdcc.4/polling |
| 300 | |
| 301 | # Chown polling nodes as needed from UI running on system server |
| 302 | chown system system /sys/devices/platform/msm_sdcc.1/polling |
| 303 | chown system system /sys/devices/platform/msm_sdcc.2/polling |
| 304 | chown system system /sys/devices/platform/msm_sdcc.3/polling |
| 305 | chown system system /sys/devices/platform/msm_sdcc.4/polling |
| 306 | |
| 307 | #Create the symlink to qcn wpa_supplicant folder for ar6000 wpa_supplicant |
| 308 | #symlink /data/misc/wifi/wpa_supplicant /data/system/wpa_supplicant |
| 309 | |
| 310 | #Create directories for Location services |
| 311 | mkdir /data/vendor/location 0770 gps gps |
| 312 | mkdir /data/vendor/location/mq 0770 gps gps |
| 313 | mkdir /data/vendor/location/xtwifi 0770 gps gps |
| 314 | mkdir /dev/socket/location 0770 gps gps |
| 315 | mkdir /dev/socket/location/mq 0770 gps gps |
| 316 | mkdir /dev/socket/location/xtra 0770 gps gps |
| 317 | mkdir /dev/socket/location/dgnss 0770 gps gps |
| 318 | |
| 319 | #Create directories for wifihal services |
| 320 | mkdir /dev/socket/wifihal 0770 wifi wifi |
| 321 | chmod 2770 /dev/socket/wifihal |
| 322 | |
| 323 | # Create /data/time folder for time-services |
| 324 | mkdir /data/vendor/time/ 0700 system system |
| 325 | |
| 326 | setprop vold.post_fs_data_done 1 |
| 327 | |
| 328 | #Create a folder for SRS to be able to create a usercfg file |
| 329 | #mkdir /data/data/media 0770 media media |
| 330 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 331 | #Create PERFD deamon related dirs |
| 332 | mkdir /data/vendor/perfd 0770 root system |
| 333 | chmod 2770 /data/vendor/perfd |
| 334 | rm /data/vendor/perfd/default_values |
| 335 | |
| 336 | mkdir /data/vendor/secure_element 0777 system system |
| 337 | |
| 338 | #Create IOP deamon related dirs |
| 339 | mkdir /data/vendor/iop 0700 root system |
| 340 | |
| 341 | # Mark the copy complete flag to not completed |
| 342 | write /data/vendor/radio/copy_complete 0 |
| 343 | chown radio radio /data/vendor/radio/copy_complete |
| 344 | chmod 0660 /data/vendor/radio/copy_complete |
| 345 | |
| 346 | # copy prebuilt qcril.db files always |
| 347 | copy /vendor/radio/qcril_database/qcril.db /data/vendor/radio/qcril_prebuilt.db |
| 348 | chown radio radio /data/vendor/radio/qcril_prebuilt.db |
| 349 | chmod 0660 /data/vendor/radio/qcril_prebuilt.db |
| 350 | copy /vendor/radio/qcril_database/qcrilNr.db /data/vendor/radio/qcrilNr_prebuilt.db |
| 351 | copy /vendor/etc/qcril_database/qcrilNr.db /data/vendor/radio/qcrilNr_prebuilt.db |
| 352 | chown radio radio /data/vendor/radio/qcrilNr_prebuilt.db |
| 353 | chmod 0660 /data/vendor/radio/qcrilNr_prebuilt.db |
| 354 | |
| 355 | # File flags for prebuilt ril db file |
| 356 | write /data/vendor/radio/prebuilt_db_support 1 |
| 357 | chown radio radio /data/vendor/radio/prebuilt_db_support |
| 358 | chmod 0400 /data/vendor/radio/prebuilt_db_support |
| 359 | write /data/vendor/radio/db_check_done 0 |
| 360 | chown radio radio /data/vendor/radio/db_check_done |
| 361 | chmod 0660 /data/vendor/radio/db_check_done |
| 362 | |
| 363 | # qti-logkit data |
| 364 | mkdir /data/vendor/qti-logkit/ 0771 system system |
| 365 | mkdir /data/vendor/qti-logkit/shared-privileged/ 2770 system system |
| 366 | mkdir /data/vendor/qti-logkit/shared-public/ 2770 system diag |
| 367 | mkdir /data/vendor/qti-logkit/socket-privileged/ 2770 system system |
| 368 | mkdir /data/vendor/qti-logkit/socket-public/ 2750 system diag |
| 369 | mkdir /data/vendor/qti-logkit/logdata/ 2750 system shell |
| 370 | |
| 371 | #Create SWAP related dirs |
| 372 | mkdir /data/vendor/swap 0770 root system |
| 373 | chmod 2770 /data/vendor/swap |
| 374 | |
| 375 | # set aggressive read ahead for dm-0 and dm-1 during boot up |
| 376 | write /sys/block/dm-0/queue/read_ahead_kb 2048 |
| 377 | write /sys/block/dm-1/queue/read_ahead_kb 2048 |
| 378 | write /sys/block/dm-2/queue/read_ahead_kb 2048 |
| 379 | |
| 380 | # Create vpp directory |
| 381 | mkdir /data/vendor/vpp 0770 media media |
| 382 | |
| 383 | #Create dir for TUI |
| 384 | mkdir /data/vendor/tui 0700 system drmrpc |
| 385 | |
Michael Bestas | 9bb5a14 | 2024-05-29 00:19:57 +0300 | [diff] [blame] | 386 | mkdir /data/vendor/goodix 0770 system system |
| 387 | mkdir /data/vendor/goodix/gf_data 0770 system system |
| 388 | restorecon /data/vendor/goodix/gf_data |
| 389 | chmod 0770 /mnt/vendor/persist/goodix |
| 390 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 391 | service nqnfcinfo /system/vendor/bin/nqnfcinfo |
| 392 | class late_start |
| 393 | group nfc |
| 394 | user system |
| 395 | oneshot |
| 396 | |
| 397 | service iop /system/vendor/bin/iop |
| 398 | class main |
| 399 | user root |
| 400 | group root |
| 401 | disabled |
| 402 | socket iop seqpacket 0666 root system |
| 403 | |
| 404 | service qcomsysd /system/vendor/bin/qcom-system-daemon |
| 405 | class main |
| 406 | user root |
| 407 | group root diag oem_2901 |
| 408 | disabled |
| 409 | |
| 410 | on property:persist.vendor.qcomsysd.enabled=1 |
| 411 | enable qcomsysd |
| 412 | |
| 413 | on property:persist.vendor.qcomsysd.enabled=0 |
| 414 | stop qcomsysd |
| 415 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 416 | on property:ro.vendor.iocgrp.config=1 |
| 417 | mkdir /dev/blkio |
| 418 | mount cgroup none /dev/blkio blkio |
| 419 | chown system system /dev/blkio |
| 420 | chown system system /dev/blkio/tasks |
| 421 | chmod 0664 /dev/blkio/tasks |
| 422 | mkdir /dev/blkio/bg 0755 system system |
| 423 | chown system system /dev/blkio/bg/tasks |
| 424 | chmod 0664 /dev/blkio/bg/tasks |
| 425 | write /dev/blkio/blkio.weight 1000 |
| 426 | write /dev/blkio/bg/blkio.weight 100 |
| 427 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 428 | on property:persist.sys.mba_boot_timeout=* |
| 429 | write /sys/module/pil_msa/parameters/pbl_mba_boot_timeout_ms ${persist.sys.mba_boot_timeout} |
| 430 | |
| 431 | on property:persist.sys.modem_auth_timeout=* |
| 432 | write /sys/module/pil_msa/parameters/modem_auth_timeout_ms ${persist.sys.modem_auth_timeout} |
| 433 | |
| 434 | on property:persist.sys.pil_proxy_timeout=* |
| 435 | write /sys/module/peripheral_loader/parameters/proxy_timeout_ms ${persist.sys.pil_proxy_timeout} |
| 436 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 437 | on property:persist.vendor.sys.rawdump_copy=1 |
| 438 | write /sys/kernel/dload/emmc_dload 1 |
| 439 | |
| 440 | on property:persist.vendor.sys.rawdump_copy=0 |
| 441 | write /sys/kernel/dload/emmc_dload 0 |
| 442 | |
| 443 | on property:sys.boot_completed=1 |
| 444 | write /dev/kmsg "Boot completed " |
| 445 | #Enable UFS clock scaling back |
| 446 | write /sys/bus/platform/devices/1d84000.ufshc/clkscale_enable 1 |
| 447 | #Reset read ahead for dm-0 and dm-1 to 512kb |
| 448 | write /sys/block/dm-0/queue/read_ahead_kb 512 |
| 449 | write /sys/block/dm-1/queue/read_ahead_kb 512 |
| 450 | #WDSP FW boot sysfs node used by STHAL |
| 451 | chown media audio /sys/kernel/wdsp0/boot |
| 452 | chown media audio /sys/kernel/wcd_cpe0/fw_name |
| 453 | #Reinit lmkd to reconfigure lmkd properties |
| 454 | setprop lmkd.reinit 1 |
| 455 | |
Michael Bestas | 9bb5a14 | 2024-05-29 00:19:57 +0300 | [diff] [blame] | 456 | on property:persist.sys.dynamic_fps=0 |
| 457 | write /sys/class/display/panel/dynamic_fps 0 |
| 458 | on property:persist.sys.dynamic_fps=1 |
| 459 | write /sys/class/display/panel/dynamic_fps 1 |
| 460 | on property:persist.sys.dynamic_fps=2 |
| 461 | write /sys/class/display/panel/dynamic_fps 2 |
| 462 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 463 | # corefile limit |
| 464 | on property:persist.debug.trace=1 |
| 465 | mkdir /data/core 0777 root root |
| 466 | write /proc/sys/kernel/core_pattern "/data/core/%E.%p.%e" |
| 467 | |
| 468 | on property:vendor.media.target.version=* |
| 469 | setprop vendor.sys.media.target.version ${vendor.media.target.version} |
| 470 | |
| 471 | on property:vendor.netflix.bsp_rev=* |
| 472 | setprop ro.netflix.bsp_rev ${vendor.netflix.bsp_rev} |
| 473 | |
| 474 | on property:vendor.media.target_variant=* |
| 475 | setprop ro.media.xml_variant.codecs ${vendor.media.target_variant} |
| 476 | setprop ro.media.xml_variant.codecs_performance ${vendor.media.target_variant} |
| 477 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 478 | service qcom-c_main-sh /vendor/bin/init.class_main.sh |
| 479 | class main |
| 480 | user root |
| 481 | group root system |
| 482 | oneshot |
| 483 | |
| 484 | on property:vold.decrypt=trigger_restart_framework |
| 485 | start qcom-c_main-sh |
| 486 | start wcnss-service |
| 487 | |
Michael Bestas | 9bb5a14 | 2024-05-29 00:19:57 +0300 | [diff] [blame] | 488 | on property:persist.sys.fts_gesture_mode=0 |
| 489 | write /sys/bus/i2c/devices/3-0038/fts_gesture_mode 0 |
| 490 | |
| 491 | on property:persist.sys.fts_gesture_mode=1 |
| 492 | write /sys/bus/i2c/devices/3-0038/fts_gesture_mode 1 |
| 493 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 494 | service vendor.qrtr-ns /vendor/bin/qrtr-ns -f |
| 495 | class core |
| 496 | user vendor_qrtr |
| 497 | group vendor_qrtr |
| 498 | capabilities NET_BIND_SERVICE |
| 499 | |
| 500 | service irsc_util /vendor/bin/irsc_util "/vendor/etc/sec_config" |
| 501 | class core |
| 502 | user root |
| 503 | oneshot |
| 504 | |
| 505 | service qmiproxy /system/bin/qmiproxy |
| 506 | class main |
| 507 | user radio |
| 508 | group radio diag |
| 509 | disabled |
| 510 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 511 | # Data Migration |
| 512 | service vendor.move_wifi_data /system/bin/move_wifi_data.sh |
| 513 | class main |
| 514 | user wifi |
| 515 | group wifi |
| 516 | disabled |
| 517 | oneshot |
| 518 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 519 | service ptt_socket_app /system/vendor/bin/ptt_socket_app -d |
| 520 | class main |
| 521 | user wifi |
| 522 | group wifi system inet net_admin |
| 523 | capabilities NET_ADMIN |
| 524 | oneshot |
| 525 | |
| 526 | service ptt_ffbm /system/vendor/bin/ptt_socket_app -f -d |
| 527 | user root |
| 528 | group root |
| 529 | disabled |
| 530 | oneshot |
| 531 | |
| 532 | service wifi_ftmd /system/vendor/bin/wifi_ftmd |
| 533 | user system |
| 534 | group system inet net_admin |
| 535 | socket wififtmd_server dgram 0660 system system |
| 536 | disabled |
| 537 | oneshot |
| 538 | |
| 539 | on property:vendor.wifi.ftmd.load=true |
| 540 | insmod /system/lib/modules/pronto/pronto_wlan.ko con_mode=5 |
| 541 | |
| 542 | service cnss-daemon /system/vendor/bin/cnss-daemon -n -l |
| 543 | class late_start |
| 544 | user system |
| 545 | group system inet net_admin wifi |
| 546 | capabilities NET_ADMIN |
| 547 | |
| 548 | on property:sys.shutdown.requested=* |
| 549 | write /sys/kernel/shutdown_wlan/shutdown 1 |
| 550 | stop cnss-daemon |
| 551 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 552 | service ssgqmigd /vendor/bin/ssgqmigd |
| 553 | class late_start |
| 554 | user radio |
| 555 | group radio gps system |
| 556 | socket ssgqmig seqpacket 0660 radio inet |
| 557 | |
| 558 | service mlid /vendor/bin/mlid |
| 559 | class late_start |
| 560 | user gps |
| 561 | group gps |
| 562 | socket mlid stream 0666 gps gps |
| 563 | |
| 564 | service loc_launcher /system/vendor/bin/loc_launcher |
| 565 | class late_start |
| 566 | user gps |
| 567 | group gps |
| 568 | |
Michael Bestas | 05ca34d | 2023-05-05 20:09:13 +0300 | [diff] [blame] | 569 | on property:persist.sys.xtra-daemon.enabled=* |
| 570 | restart loc_launcher |
| 571 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 572 | service qcom-sh /vendor/bin/init.qcom.sh |
| 573 | class late_start |
| 574 | user root |
| 575 | group root system radio |
| 576 | oneshot |
| 577 | # Remove since is deprecated but throws AVC denial. |
| 578 | # service crashdata-sh /vendor/bin/init.qcom.crashdata.sh |
| 579 | # class late_start |
| 580 | # user root |
| 581 | # oneshot |
| 582 | |
| 583 | service qcom-post-boot /vendor/bin/init.qcom.post_boot.sh |
| 584 | class late_start |
| 585 | user root |
| 586 | group root system wakelock graphics |
| 587 | disabled |
| 588 | oneshot |
| 589 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 590 | on property:sys.boot_completed=1 |
| 591 | start qcom-post-boot |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 592 | |
| 593 | on property:ro.vendor.ril.mbn_copy_completed=1 |
| 594 | write /data/vendor/radio/copy_complete 1 |
| 595 | |
| 596 | service qvop-daemon /vendor/bin/qvop-daemon |
| 597 | class late_start |
| 598 | user system |
| 599 | group system drmrpc |
| 600 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 601 | service hostapd_fst /vendor/bin/hw/hostapd -dd -g /data/vendor/wifi/hostapd/global |
| 602 | class main |
| 603 | capabilities NET_ADMIN NET_RAW |
| 604 | user wifi |
| 605 | group wifi |
| 606 | disabled |
| 607 | oneshot |
| 608 | |
| 609 | service battery_monitor /system/bin/battery_monitor |
| 610 | user system |
| 611 | group system |
| 612 | disabled |
| 613 | |
| 614 | service vendor.ril-daemon2 /vendor/bin/hw/rild -c 2 |
| 615 | class main |
| 616 | user radio |
| 617 | disabled |
| 618 | group radio cache inet misc audio sdcard_r sdcard_rw diag oem_2901 log |
| 619 | capabilities BLOCK_SUSPEND NET_ADMIN NET_RAW |
| 620 | |
| 621 | service vendor.ril-daemon3 /vendor/bin/hw/rild -c 3 |
| 622 | class main |
| 623 | user radio |
| 624 | disabled |
| 625 | group radio cache inet misc audio sdcard_r sdcard_rw diag oem_2901 log |
| 626 | capabilities BLOCK_SUSPEND NET_ADMIN NET_RAW |
| 627 | |
| 628 | service profiler_daemon /system/bin/profiler_daemon |
| 629 | class late_start |
| 630 | user root |
| 631 | group root |
| 632 | disabled |
| 633 | |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 634 | service diag_mdlog_start /system/vendor/bin/diag_mdlog |
| 635 | class late_start |
| 636 | user shell |
| 637 | group system oem_2901 sdcard_rw sdcard_r media_rw |
| 638 | disabled |
| 639 | oneshot |
| 640 | |
| 641 | service diag_mdlog_stop /system/vendor/bin/diag_mdlog -k |
| 642 | class late_start |
| 643 | user shell |
| 644 | group system oem_2901 sdcard_rw sdcard_r media_rw |
| 645 | disabled |
| 646 | oneshot |
| 647 | |
| 648 | service qlogd /system/xbin/qlogd |
| 649 | socket qlogd stream 0662 system system |
| 650 | class main |
| 651 | disabled |
| 652 | on property:persist.sys.qlogd=1 |
| 653 | start qlogd |
| 654 | on property:persist.sys.qlogd=0 |
| 655 | stop qlogd |
| 656 | |
| 657 | service vm_bms /vendor/bin/vm_bms |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 658 | user root |
Rohit R Sekhar | adf4971 | 2022-11-17 21:05:16 +0530 | [diff] [blame] | 659 | group root |
| 660 | disabled |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 661 | |
| 662 | service vendor.msm_irqbalance /vendor/bin/msm_irqbalance -f /system/vendor/etc/msm_irqbalance.conf |
| 663 | class core |
| 664 | user root |
| 665 | group root |
| 666 | disabled |
| 667 | |
| 668 | service vendor.msm_irqbal_lb /vendor/bin/msm_irqbalance -f /system/vendor/etc/msm_irqbalance_little_big.conf |
| 669 | class core |
| 670 | user root |
| 671 | group root |
| 672 | disabled |
| 673 | |
| 674 | service vendor.msm_irqbl_sdm630 /vendor/bin/msm_irqbalance -f /system/vendor/etc/msm_irqbalance_sdm630.conf |
| 675 | class core |
| 676 | user root |
| 677 | group root |
| 678 | disabled |
| 679 | |
| 680 | # service for USERDEBUG |
| 681 | service vendor.LKCore-dbg /vendor/bin/LKCore |
| 682 | class late_start |
| 683 | oneshot |
| 684 | disabled |
| 685 | user root |
| 686 | group root system log diag net_raw |
| 687 | |
| 688 | # service for USER |
| 689 | service vendor.LKCore-rel /vendor/bin/LKCore |
| 690 | class late_start |
| 691 | oneshot |
| 692 | disabled |
| 693 | user system |
| 694 | group system log diag |
| 695 | |
| 696 | service qseeproxydaemon /system/vendor/bin/qseeproxydaemon |
| 697 | class late_start |
| 698 | user system |
| 699 | group system |
| 700 | |
| 701 | service esepmdaemon /system/vendor/bin/esepmdaemon |
| 702 | class core |
| 703 | user system |
| 704 | group nfc |
| 705 | |
| 706 | on charger |
| 707 | setprop persist.sys.usb.config mass_storage |
| 708 | start qcom-post-boot |
| 709 | |
| 710 | #add poweroffhandler |
| 711 | service poweroffhandler /system/vendor/bin/poweroffhandler |
| 712 | class core |
| 713 | user media |
| 714 | group graphics audio |
| 715 | disabled |
| 716 | oneshot |
| 717 | |
| 718 | service time_daemon /vendor/bin/time_daemon |
| 719 | class main |
| 720 | user system |
| 721 | group system |
| 722 | capabilities SYS_TIME |
| 723 | |
| 724 | # Set vendor-ril lib path based on Meta version |
| 725 | on property:vendor.rild.libpath=* |
| 726 | setprop rild.libpath ${vendor.rild.libpath} |
| 727 | |
| 728 | on property:ro.vendor.radio.noril=* |
| 729 | setprop ro.radio.noril ${ro.vendor.radio.noril} |
| 730 | |
| 731 | service vendor.power_off_alarm /vendor/bin/power_off_alarm |
| 732 | class core |
| 733 | group system |
| 734 | disabled |
| 735 | oneshot |
| 736 | |
| 737 | service vendor.hbtp /vendor/bin/hbtp_daemon |
| 738 | class main |
| 739 | user system |
| 740 | group system |
| 741 | capabilities SYS_NICE |
| 742 | disabled |
| 743 | |
| 744 | service chre /vendor/bin/chre |
| 745 | class late_start |
| 746 | user system |
| 747 | group system |
| 748 | socket chre seqpacket 0660 root system |
| 749 | shutdown critical |
| 750 | |
| 751 | on property:vendor.chre.enabled=0 |
| 752 | stop chre |
| 753 | |
| 754 | service bugreport /system/bin/dumpstate -d -p -B -z -o /data/user_de/0/com.android.shell/files/bugreports/bugreport |
| 755 | class main |
| 756 | disabled |
| 757 | oneshot |
| 758 | keycodes 114 115 116 |
| 759 | |
| 760 | #Set GPU Opengles version |
| 761 | on property:vendor.opengles.version=* |
| 762 | setprop ro.opengles.version ${vendor.opengles.version} |
| 763 | |
| 764 | #Set gpu available frequencies property |
| 765 | on property:vendor.gpu.available_frequencies=* |
| 766 | setprop ro.vendor.gpu.available_frequencies ${vendor.gpu.available_frequencies} |
| 767 | |
| 768 | service vendor.audio-hal /vendor/bin/hw/android.hardware.audio.service |
| 769 | override |
| 770 | class hal |
| 771 | user audioserver |
Michael Bestas | 0a0f54b | 2021-01-01 02:16:24 +0200 | [diff] [blame] | 772 | # media gid needed for /data/misc/media (tee) |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 773 | group audio camera drmrpc inet media mediadrm net_bt net_bt_admin net_bw_acct oem_2901 wakelock |
| 774 | capabilities BLOCK_SUSPEND |
| 775 | ioprio rt 4 |
Suren Baghdasaryan | 8e82c1f | 2020-04-30 13:30:47 -0700 | [diff] [blame] | 776 | task_profiles ProcessCapacityHigh HighPerformance |
merothh | 32be688 | 2022-01-03 01:54:57 +0530 | [diff] [blame] | 777 | onrestart restart audioserver |