summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMinchan Kim <minchan@google.com>2018-10-19 18:12:44 +0900
committerTim Murray <timmurray@google.com>2018-10-25 17:10:21 -0700
commite88ca261c4f88de8500085eb0a779a61d0b11334 (patch)
tree5bcf89411ab62c9c5154ea7343ac3d4a7cd02ff9
parent3c3cf01f95e40d02e30282a0cc0c78ffb758bc59 (diff)
Change zram swap size and swappiness
This CL increase zram swap size from 512M to 1024M of p18. It also increase swappiness from 60 to 100. It has more benefit for overall system performance. Detail is in the bug. Bug: 117522738 Test: confirmed zram size and swappiness change manually Change-Id: I4cbb8e7d5a43d6a273c53e8d5ed2976109a3ea5e Signed-off-by: Minchan Kim <minchan@google.com>
-rw-r--r--fstab.hardware2
-rw-r--r--init.hardware.rc1
2 files changed, 2 insertions, 1 deletions
diff --git a/fstab.hardware b/fstab.hardware
index 406b09a..38401d8 100644
--- a/fstab.hardware
+++ b/fstab.hardware
@@ -7,4 +7,4 @@
/dev/block/bootdevice/by-name/misc /misc emmc defaults defaults
/dev/block/bootdevice/by-name/modem /vendor/firmware_mnt vfat ro,shortname=lower,uid=1000,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait,slotselect
/devices/platform/soc/a600000.ssusb/a600000.dwc3* auto vfat defaults voldmanaged=usb:auto
-/dev/block/zram0 none swap defaults zramsize=536870912,max_comp_streams=8
+/dev/block/zram0 none swap defaults zramsize=1073741824,max_comp_streams=8
diff --git a/init.hardware.rc b/init.hardware.rc
index c7888e5..80406dc 100644
--- a/init.hardware.rc
+++ b/init.hardware.rc
@@ -576,6 +576,7 @@ on property:sys.boot_completed=1
# Enable ZRAM on boot_complete
swapon_all /vendor/etc/fstab.${ro.boot.hardware.platform}
+ write /proc/sys/vm/swappiness 100
# Setup final cpuset
write /dev/cpuset/top-app/cpus 0-7