mirror of
https://github.com/Evolution-X-Devices/device_xiaomi_sm6150-common
synced 2026-01-27 12:07:36 +00:00
davinci: rootdir: Don't configure zram in init.qcom.post_boot.sh
* let it use the size which is set in fstab Change-Id: Ie84d0674a643e637d5ef894399d76ede25d00eeb
This commit is contained in:
@@ -29,13 +29,6 @@
|
|||||||
|
|
||||||
target=`getprop ro.board.platform`
|
target=`getprop ro.board.platform`
|
||||||
|
|
||||||
function configure_zram_parameters() {
|
|
||||||
# Set Zram disk size=1GB for >=2GB Non-Go targets.
|
|
||||||
echo 2684350464 > /sys/block/zram0/disksize
|
|
||||||
mkswap /dev/block/zram0
|
|
||||||
swapon /dev/block/zram0 -p 32758
|
|
||||||
}
|
|
||||||
|
|
||||||
function configure_memory_parameters() {
|
function configure_memory_parameters() {
|
||||||
# Set Memory parameters.
|
# Set Memory parameters.
|
||||||
#
|
#
|
||||||
@@ -81,13 +74,6 @@ function configure_memory_parameters() {
|
|||||||
# use Google default LMK series for all 64-bit targets >=2GB.
|
# use Google default LMK series for all 64-bit targets >=2GB.
|
||||||
echo 1 > /sys/module/lowmemorykiller/parameters/enable_adaptive_lmk
|
echo 1 > /sys/module/lowmemorykiller/parameters/enable_adaptive_lmk
|
||||||
echo 1 > /sys/module/lowmemorykiller/parameters/oom_reaper
|
echo 1 > /sys/module/lowmemorykiller/parameters/oom_reaper
|
||||||
|
|
||||||
# Set allocstall_threshold to 0
|
|
||||||
# Set swappiness to 100
|
|
||||||
echo 0 > /sys/module/vmpressure/parameters/allocstall_threshold
|
|
||||||
echo 100 > /proc/sys/vm/swappiness
|
|
||||||
|
|
||||||
configure_zram_parameters
|
|
||||||
}
|
}
|
||||||
|
|
||||||
case "$target" in
|
case "$target" in
|
||||||
|
|||||||
@@ -135,6 +135,14 @@ on property:sys.boot_completed=1
|
|||||||
write /sys/module/cpu_boost/parameters/input_boost_freq "0:1324800"
|
write /sys/module/cpu_boost/parameters/input_boost_freq "0:1324800"
|
||||||
write /sys/module/cpu_boost/parameters/input_boost_ms 120
|
write /sys/module/cpu_boost/parameters/input_boost_ms 120
|
||||||
|
|
||||||
|
# Set allocstall_threshold to 0
|
||||||
|
# Set swappiness to 100
|
||||||
|
write /sys/module/vmpressure/parameters/allocstall_threshold 0
|
||||||
|
write /proc/sys/vm/swappiness 100
|
||||||
|
|
||||||
|
# Enable ZRAM on boot_complete
|
||||||
|
swapon_all /vendor/etc/fstab.qcom
|
||||||
|
|
||||||
service vendor.pd_mapper /vendor/bin/pd-mapper
|
service vendor.pd_mapper /vendor/bin/pd-mapper
|
||||||
class core
|
class core
|
||||||
user system
|
user system
|
||||||
|
|||||||
Reference in New Issue
Block a user