aboutsummaryrefslogtreecommitdiffstats
path: root/features/rt/kernel-sched-add-put-get-_cpu_light.patch
diff options
context:
space:
mode:
Diffstat (limited to 'features/rt/kernel-sched-add-put-get-_cpu_light.patch')
-rw-r--r--features/rt/kernel-sched-add-put-get-_cpu_light.patch27
1 files changed, 27 insertions, 0 deletions
diff --git a/features/rt/kernel-sched-add-put-get-_cpu_light.patch b/features/rt/kernel-sched-add-put-get-_cpu_light.patch
new file mode 100644
index 00000000..8cb9d552
--- /dev/null
+++ b/features/rt/kernel-sched-add-put-get-_cpu_light.patch
@@ -0,0 +1,27 @@
+From 7497b8dc12591dd237a63c9748b71666d48a2eb4 Mon Sep 17 00:00:00 2001
+From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
+Date: Sat, 27 May 2017 19:02:06 +0200
+Subject: [PATCH 101/191] kernel/sched: add {put|get}_cpu_light()
+
+Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
+---
+ include/linux/smp.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/include/linux/smp.h b/include/linux/smp.h
+index 70c6f6284dcf..4c602ca3bc13 100644
+--- a/include/linux/smp.h
++++ b/include/linux/smp.h
+@@ -238,6 +238,9 @@ static inline int get_boot_cpu_id(void)
+ #define get_cpu() ({ preempt_disable(); __smp_processor_id(); })
+ #define put_cpu() preempt_enable()
+
++#define get_cpu_light() ({ migrate_disable(); __smp_processor_id(); })
++#define put_cpu_light() migrate_enable()
++
+ /*
+ * Callback to arch code if there's nosmp or maxcpus=0 on the
+ * boot command line:
+--
+2.19.1
+