summaryrefslogtreecommitdiff
path: root/recipes-kernel/linux/linux-toradex-rt-4.9-2.3.x/002k.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-kernel/linux/linux-toradex-rt-4.9-2.3.x/002k.patch')
-rw-r--r--recipes-kernel/linux/linux-toradex-rt-4.9-2.3.x/002k.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-toradex-rt-4.9-2.3.x/002k.patch b/recipes-kernel/linux/linux-toradex-rt-4.9-2.3.x/002k.patch
new file mode 100644
index 0000000..09c6527
--- /dev/null
+++ b/recipes-kernel/linux/linux-toradex-rt-4.9-2.3.x/002k.patch
@@ -0,0 +1,31 @@
+--- b/kernel/cpu.c
++++ a/kernel/cpu.c
+@@ -955,19 +955,20 @@
+ return ret;
+ }
+
+-static int cpu_down_maps_locked(unsigned int cpu, enum cpuhp_state target)
+-{
+- if (cpu_hotplug_disabled)
+- return -EBUSY;
+- return _cpu_down(cpu, 0, target);
+-}
+-
+ static int do_cpu_down(unsigned int cpu, enum cpuhp_state target)
+ {
+ int err;
+
+ cpu_maps_update_begin();
++
++ if (cpu_hotplug_disabled) {
++ err = -EBUSY;
++ goto out;
++ }
++
++ err = _cpu_down(cpu, 0, target);
++
++out:
+- err = cpu_down_maps_locked(cpu, target);
+ cpu_maps_update_done();
+ return err;
+ }