DivestOS/Patches/LineageOS-17.1/android_system_core/0002-HM-Increase_vm_mmc.patch

26 lines
812 B
Diff
Raw Normal View History

From 7c118662b8ea517145b30c2805fccb47698b3390 Mon Sep 17 00:00:00 2001
From: Daniel Micay <danielmicay@gmail.com>
Date: Thu, 13 Dec 2018 09:26:25 -0500
Subject: [PATCH] increase max_map_count for hardened malloc
---
rootdir/init.rc | 2 ++
1 file changed, 2 insertions(+)
diff --git a/rootdir/init.rc b/rootdir/init.rc
index c80acdf51..21075a552 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -686,6 +686,8 @@ on boot
chown root system /sys/block/zram0/writeback
chmod 0664 /sys/block/zram0/writeback
+ write /proc/sys/vm/max_map_count 524240
+
# F2FS tuning. Set cp_interval larger than dirty_expire_centisecs, 30 secs,
# to avoid power consumption when system becomes mostly idle. Be careful
# to make it too large, since it may bring userdata loss, if they
--
2.26.2