summarylogtreecommitdiffstats
path: root/0028-ZEN-INTERACTIVE-mm-Disable-proactive-compaction-by-d.patch
diff options
context:
space:
mode:
Diffstat (limited to '0028-ZEN-INTERACTIVE-mm-Disable-proactive-compaction-by-d.patch')
-rw-r--r--0028-ZEN-INTERACTIVE-mm-Disable-proactive-compaction-by-d.patch45
1 files changed, 45 insertions, 0 deletions
diff --git a/0028-ZEN-INTERACTIVE-mm-Disable-proactive-compaction-by-d.patch b/0028-ZEN-INTERACTIVE-mm-Disable-proactive-compaction-by-d.patch
new file mode 100644
index 000000000000..906a7f805aa5
--- /dev/null
+++ b/0028-ZEN-INTERACTIVE-mm-Disable-proactive-compaction-by-d.patch
@@ -0,0 +1,45 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Sultan Alsawaf <sultan@kerneltoast.com>
+Date: Sat, 24 Oct 2020 22:17:49 -0700
+Subject: [PATCH] ZEN: INTERACTIVE: mm: Disable proactive compaction by default
+
+On-demand compaction works fine assuming that you don't have a need to
+spam the page allocator nonstop for large order page allocations.
+
+Signed-off-by: Sultan Alsawaf <sultan@kerneltoast.com>
+---
+ init/Kconfig | 1 +
+ mm/compaction.c | 4 ++++
+ 2 files changed, 5 insertions(+)
+
+diff --git a/init/Kconfig b/init/Kconfig
+index 0e478db562b0..b7c05783bde6 100644
+--- a/init/Kconfig
++++ b/init/Kconfig
+@@ -122,6 +122,7 @@ config ZEN_INTERACTIVE
+ Background-reclaim hugepages...: no -> yes
+ MG-LRU minimum cache TTL.......: 0 -> 1000 ms
+ Compact Unevictable............: 1 -> 0
++ Proactive Compaction...........: 20 -> 0
+
+ --- CFS CPU Scheduler ----------------------------------
+
+diff --git a/mm/compaction.c b/mm/compaction.c
+index f713c3ca03fa..63c536175152 100644
+--- a/mm/compaction.c
++++ b/mm/compaction.c
+@@ -2705,7 +2705,11 @@ static void compact_nodes(void)
+ * aggressively the kernel should compact memory in the
+ * background. It takes values in the range [0, 100].
+ */
++#ifdef CONFIG_ZEN_INTERACTIVE
++unsigned int __read_mostly sysctl_compaction_proactiveness;
++#else
+ unsigned int __read_mostly sysctl_compaction_proactiveness = 20;
++#endif
+
+ int compaction_proactiveness_sysctl_handler(struct ctl_table *table, int write,
+ void *buffer, size_t *length, loff_t *ppos)
+--
+2.35.1
+