a7xelte: ramdisk: tune VM parameters to fix issues with MTP
authorDanny Wood <danwood76@gmail.com>
Fri, 17 May 2019 07:40:35 +0000 (08:40 +0100)
committerSourajit Karmakar <sourajit.karmakar@gmail.com>
Tue, 7 Jul 2020 15:01:47 +0000 (11:01 -0400)
Change-Id: I5fc5deeb15594cb81d8200157f86a99394f5d017

ramdisk/etc/init.target.rc

index 854c1be8eaafc98b486aa3ded9f3442570c6d8a8..2dce079c4c2a7498f7616bd8ea4541ac2a0be353 100644 (file)
@@ -4,6 +4,13 @@ on boot
     write /proc/sys/net/core/rmem_max 2097152
     write /proc/sys/net/core/wmem_max 2097152
 
+    # Set min_free_kbytes to keep larger VM chuncks lying around
+    write /proc/sys/vm/min_free_kbytes 32768
+
+    # Tune virtual memory
+    write /proc/sys/vm/swappiness 160
+    write /proc/sys/vm/vfs_cache_pressure 50
+
 on fs
     # Permissions for LCD
     chown system system /sys/class/lcd/panel/ldu_correction