summaryrefslogtreecommitdiffstats
path: root/debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 10:06:00 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 10:06:00 +0000
commitb15a952c52a6825376d3e7f6c1bf5c886c6d8b74 (patch)
tree1500f2f8f276908a36d8126cb632c0d6b1276764 /debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch
parentAdding upstream version 5.10.209. (diff)
downloadlinux-debian.tar.xz
linux-debian.zip
Adding debian version 5.10.209-2.debian/5.10.209-2debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch')
-rw-r--r--debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch39
1 files changed, 39 insertions, 0 deletions
diff --git a/debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch b/debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch
new file mode 100644
index 000000000..486873119
--- /dev/null
+++ b/debian/patches-rt/0202-mm-page_alloc-Use-migrate_disable-in-drain_local_pag.patch
@@ -0,0 +1,39 @@
+From 4c4d7886b6c8d16df841ac103b4742481ad5f014 Mon Sep 17 00:00:00 2001
+From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
+Date: Thu, 2 Jul 2020 14:27:23 +0200
+Subject: [PATCH 202/323] mm/page_alloc: Use migrate_disable() in
+ drain_local_pages_wq()
+Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/5.10/older/patches-5.10.204-rt100.tar.xz
+
+drain_local_pages_wq() disables preemption to avoid CPU migration during
+CPU hotplug.
+Using migrate_disable() makes the function preemptible on PREEMPT_RT but
+still avoids CPU migrations during CPU-hotplug. On !PREEMPT_RT it
+behaves like preempt_disable().
+
+Use migrate_disable() in drain_local_pages_wq().
+
+Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
+---
+ mm/page_alloc.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/mm/page_alloc.c b/mm/page_alloc.c
+index a3f1e4c6bdc8..508650843235 100644
+--- a/mm/page_alloc.c
++++ b/mm/page_alloc.c
+@@ -3048,9 +3048,9 @@ static void drain_local_pages_wq(struct work_struct *work)
+ * cpu which is allright but we also have to make sure to not move to
+ * a different one.
+ */
+- preempt_disable();
++ migrate_disable();
+ drain_local_pages(drain->zone);
+- preempt_enable();
++ migrate_enable();
+ }
+
+ /*
+--
+2.43.0
+