2020-05-18 01:42:10 -04:00
|
|
|
on init
|
|
|
|
# Disable powersaving
|
|
|
|
write /sys/module/lpm_levels/parameters/sleep_disabled 1
|
|
|
|
|
|
|
|
# bring back all cores
|
|
|
|
write /sys/devices/system/cpu/cpu0/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu1/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu2/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu3/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu4/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu5/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu6/online 1
|
|
|
|
write /sys/devices/system/cpu/cpu7/online 1
|
|
|
|
|
|
|
|
# configure governor settings for little cluster
|
|
|
|
write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor schedutil
|
|
|
|
write /sys/devices/system/cpu/cpu0/cpufreq/schedutil/up_rate_limit_us 500
|
|
|
|
write /sys/devices/system/cpu/cpu0/cpufreq/schedutil/down_rate_limit_us 20000
|
|
|
|
|
|
|
|
# configure governor settings for big cluster
|
|
|
|
write /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor schedutil
|
|
|
|
write /sys/devices/system/cpu/cpu6/cpufreq/schedutil/up_rate_limit_us 500
|
|
|
|
write /sys/devices/system/cpu/cpu6/cpufreq/schedutil/down_rate_limit_us 20000
|
|
|
|
|
|
|
|
# set default schedTune value for foreground/top-app
|
|
|
|
write /dev/stune/foreground/schedtune.prefer_idle 1
|
|
|
|
write /dev/stune/top-app/schedtune.boost 10
|
|
|
|
write /dev/stune/top-app/schedtune.prefer_idle 1
|
|
|
|
|
|
|
|
mkdir /dev/cpuset/camera-daemon
|
|
|
|
write /dev/cpuset/camera-daemon/cpus 0-7
|
|
|
|
write /dev/cpuset/camera-daemon/mems 0
|
|
|
|
chown system system /dev/cpuset/camera-daemon
|
|
|
|
chown system system /dev/cpuset/camera-daemon/tasks
|
|
|
|
chmod 0664 /dev/cpuset/camera-daemon/tasks
|
|
|
|
|
|
|
|
# b/37682684 Enable suspend clock reporting
|
|
|
|
write /sys/kernel/debug/clk/debug_suspend 1
|
|
|
|
|
|
|
|
# ZRAM setup
|
|
|
|
write /sys/block/zram0/comp_algorithm lz4
|
|
|
|
write /proc/sys/vm/page-cluster 0
|
|
|
|
|
2020-03-20 14:52:22 -04:00
|
|
|
on late-fs
|
2020-05-18 01:42:10 -04:00
|
|
|
# Runtime fs tuning
|
2020-03-20 14:52:22 -04:00
|
|
|
write /sys/block/sda/queue/iostats 0
|
|
|
|
write /sys/block/sda/queue/scheduler cfq
|
|
|
|
write /sys/block/sda/queue/read_ahead_kb 2048
|
|
|
|
write /sys/block/sda/queue/nr_requests 256
|
|
|
|
write /sys/block/dm-0/queue/read_ahead_kb 2048
|
|
|
|
write /sys/block/dm-1/queue/read_ahead_kb 2048
|
|
|
|
|
|
|
|
on property:sys.boot_completed=1
|
|
|
|
write /sys/block/sda/queue/iostats 1
|
|
|
|
write /sys/block/sda/queue/scheduler noop
|
|
|
|
write /sys/block/sda/queue/read_ahead_kb 512
|
|
|
|
write /sys/block/sda/queue/nr_requests 128
|
|
|
|
write /sys/block/dm-0/queue/read_ahead_kb 512
|
|
|
|
write /sys/block/dm-1/queue/read_ahead_kb 512
|
2020-05-18 01:42:10 -04:00
|
|
|
|
|
|
|
# Setup runtime blkio
|
|
|
|
# value for group_idle is us
|
2020-03-27 08:58:52 -04:00
|
|
|
write /dev/blkio/blkio.weight 1000
|
|
|
|
write /dev/blkio/background/blkio.weight 200
|
|
|
|
write /dev/blkio/blkio.group_idle 2000
|
|
|
|
write /dev/blkio/background/blkio.group_idle 0
|
2020-03-20 14:52:22 -04:00
|
|
|
|
2019-08-29 05:37:42 -04:00
|
|
|
on boot
|
|
|
|
# Touchscreen
|
2020-04-10 13:08:03 -04:00
|
|
|
chown system system /sys/class/touch/tp_dev/gesture_on
|
|
|
|
chown 0660 /sys/class/touch/tp_dev/gesture_on
|
2019-08-29 05:37:42 -04:00
|
|
|
|
2020-05-07 04:13:57 -04:00
|
|
|
# Light HAL
|
|
|
|
chown system system /sys/class/leds/wled/brightness
|
|
|
|
chown system system /sys/class/leds/wled/max_brightness
|
|
|
|
chown system system /sys/class/leds/red/breath
|
|
|
|
chown system system /sys/class/leds/red/brightness
|
|
|
|
chown system system /sys/class/leds/red/delay_on
|
|
|
|
chown system system /sys/class/leds/red/delay_off
|
|
|
|
chown system system /sys/class/leds/green/breath
|
|
|
|
chown system system /sys/class/leds/green/brightness
|
|
|
|
chown system system /sys/class/leds/green/delay_on
|
|
|
|
chown system system /sys/class/leds/green/delay_off
|
|
|
|
chown system system /sys/class/leds/blue/breath
|
|
|
|
chown system system /sys/class/leds/blue/brightness
|
|
|
|
chown system system /sys/class/leds/blue/delay_on
|
|
|
|
chown system system /sys/class/leds/blue/delay_off
|
|
|
|
|
|
|
|
chmod 0644 /sys/class/leds/wled/brightness
|
|
|
|
chmod 0644 /sys/class/leds/wled/max_brightness
|
|
|
|
chmod 0644 /sys/class/leds/red/breath
|
|
|
|
chmod 0644 /sys/class/leds/red/brightness
|
|
|
|
chmod 0644 /sys/class/leds/red/delay_on
|
|
|
|
chmod 0644 /sys/class/leds/red/delay_off
|
|
|
|
chmod 0644 /sys/class/leds/green/breath
|
|
|
|
chmod 0644 /sys/class/leds/green/brightness
|
|
|
|
chmod 0644 /sys/class/leds/green/delay_on
|
|
|
|
chmod 0644 /sys/class/leds/green/delay_off
|
|
|
|
chmod 0644 /sys/class/leds/blue/breath
|
|
|
|
chmod 0644 /sys/class/leds/blue/brightness
|
|
|
|
chmod 0644 /sys/class/leds/blue/delay_on
|
|
|
|
chmod 0644 /sys/class/leds/blue/delay_off
|
|
|
|
|
|
|
|
service vendor.light-hal-2-0 /vendor/bin/hw/android.hardware.light@2.0-service
|
|
|
|
interface android.hardware.light@2.0::ILight default
|
|
|
|
class hal
|
|
|
|
user system
|
|
|
|
group system
|
|
|
|
# shutting off lights while powering-off
|
|
|
|
shutdown critical
|
|
|
|
|
|
|
|
|
2019-11-05 20:01:16 -05:00
|
|
|
service cvphalservice /system/bin/true
|
|
|
|
disabled
|
|
|
|
|
2020-03-22 06:08:45 -04:00
|
|
|
service vendor.power-hal-1-0 /system/bin/true
|
|
|
|
disabled
|
2020-05-13 07:34:54 -04:00
|
|
|
|
|
|
|
service iop-hal-2-0 /system/bin/true
|
|
|
|
disabled
|
|
|
|
|
|
|
|
service perf-hal-2-0 /system/bin/true
|
|
|
|
disabled
|