summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>2015-08-16 15:33:26 +0200
committerSebastian Andrzej Siewior <bigeasy@linutronix.de>2015-08-16 15:33:26 +0200
commit1c3f128c6ea66b3f0a9df568312ce9204a6dcb28 (patch)
tree435e2a17fd2978806109a5508753444c23171957
parent1c748d69121cad7bdd08e1358dc6de69f9866122 (diff)
download4.12-rt-patches-1c3f128c6ea66b3f0a9df568312ce9204a6dcb28.tar.gz
[ANNOUNCE] 4.1.5-rt5
Dear RT folks! I'm pleased to announce the v4.1.5-rt5 patch set. Changes since v4.1.5-rt4: - don't disable preemption in dump_stack(). We should not see a backtrace on a production kernel but then it should not increase the latency if trigger one. Known issues: - bcache is disabled. - CPU hotplug works in general. Steven's test script however deadlocks usually on the second invocation. - Clark Williams reported an OOPS in netlink_release() which has not been narrowed down yet. - Nicholas Mc Guire reported high CPU usage by softirq on an idle system which seems to freeze / halt the system. The delta patch against 4.1.5-rt4 is appended below and can be found here: https://www.kernel.org/pub/linux/kernel/projects/rt/4.1/incr/patch-4.1.5-rt4-rt5.patch.xz You can get this release via the git tree at: git://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git v4.1.5-rt5 The RT patch against 4.1.5 can be found here: https://www.kernel.org/pub/linux/kernel/projects/rt/4.1/patch-4.1.5-rt5.patch.xz The split quilt queue is available at: https://www.kernel.org/pub/linux/kernel/projects/rt/4.1/patches-4.1.5-rt5.tar.xz Sebastian Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
-rw-r--r--patches/dump-stack-don-t-disable-preemption-during-trace.patch107
-rw-r--r--patches/localversion.patch2
-rw-r--r--patches/series2
3 files changed, 109 insertions, 2 deletions
diff --git a/patches/dump-stack-don-t-disable-preemption-during-trace.patch b/patches/dump-stack-don-t-disable-preemption-during-trace.patch
new file mode 100644
index 00000000000000..8bb8ff83d15091
--- /dev/null
+++ b/patches/dump-stack-don-t-disable-preemption-during-trace.patch
@@ -0,0 +1,107 @@
+From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
+Date: Sun, 16 Aug 2015 14:27:50 +0200
+Subject: dump stack: don't disable preemption during trace
+
+I see here large latencies during a stack dump on x86. The
+preempt_disable() and get_cpu() should forbid moving the task to another
+CPU during a stack dump and avoiding two stack traces in parallel on the
+same CPU. However a stack trace from a second CPU may still happen in
+parallel. Also nesting is allowed so a stack trace happens in
+process-context and we may have another one from IRQ context. With migrate
+disable we keep this code preemptible and allow a second backtrace on
+the same CPU by another task.
+
+Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
+---
+ arch/x86/kernel/dumpstack_32.c | 4 ++--
+ arch/x86/kernel/dumpstack_64.c | 8 ++++----
+ lib/dump_stack.c | 4 ++--
+ 3 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/arch/x86/kernel/dumpstack_32.c b/arch/x86/kernel/dumpstack_32.c
+index 464ffd69b92e..00db1aad1548 100644
+--- a/arch/x86/kernel/dumpstack_32.c
++++ b/arch/x86/kernel/dumpstack_32.c
+@@ -42,7 +42,7 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs,
+ unsigned long *stack, unsigned long bp,
+ const struct stacktrace_ops *ops, void *data)
+ {
+- const unsigned cpu = get_cpu();
++ const unsigned cpu = get_cpu_light();
+ int graph = 0;
+ u32 *prev_esp;
+
+@@ -86,7 +86,7 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs,
+ break;
+ touch_nmi_watchdog();
+ }
+- put_cpu();
++ put_cpu_light();
+ }
+ EXPORT_SYMBOL(dump_trace);
+
+diff --git a/arch/x86/kernel/dumpstack_64.c b/arch/x86/kernel/dumpstack_64.c
+index 5f1c6266eb30..c331e3fef465 100644
+--- a/arch/x86/kernel/dumpstack_64.c
++++ b/arch/x86/kernel/dumpstack_64.c
+@@ -152,7 +152,7 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs,
+ unsigned long *stack, unsigned long bp,
+ const struct stacktrace_ops *ops, void *data)
+ {
+- const unsigned cpu = get_cpu();
++ const unsigned cpu = get_cpu_light();
+ struct thread_info *tinfo;
+ unsigned long *irq_stack = (unsigned long *)per_cpu(irq_stack_ptr, cpu);
+ unsigned long dummy;
+@@ -241,7 +241,7 @@ void dump_trace(struct task_struct *task, struct pt_regs *regs,
+ * This handles the process stack:
+ */
+ bp = ops->walk_stack(tinfo, stack, bp, ops, data, NULL, &graph);
+- put_cpu();
++ put_cpu_light();
+ }
+ EXPORT_SYMBOL(dump_trace);
+
+@@ -255,7 +255,7 @@ show_stack_log_lvl(struct task_struct *task, struct pt_regs *regs,
+ int cpu;
+ int i;
+
+- preempt_disable();
++ migrate_disable();
+ cpu = smp_processor_id();
+
+ irq_stack_end = (unsigned long *)(per_cpu(irq_stack_ptr, cpu));
+@@ -291,7 +291,7 @@ show_stack_log_lvl(struct task_struct *task, struct pt_regs *regs,
+ pr_cont(" %016lx", *stack++);
+ touch_nmi_watchdog();
+ }
+- preempt_enable();
++ migrate_enable();
+
+ pr_cont("\n");
+ show_trace_log_lvl(task, regs, sp, bp, log_lvl);
+diff --git a/lib/dump_stack.c b/lib/dump_stack.c
+index 6745c6230db3..7ccbc6ff80ea 100644
+--- a/lib/dump_stack.c
++++ b/lib/dump_stack.c
+@@ -33,7 +33,7 @@ asmlinkage __visible void dump_stack(void)
+ * Permit this cpu to perform nested stack dumps while serialising
+ * against other CPUs
+ */
+- preempt_disable();
++ migrate_disable();
+
+ retry:
+ cpu = smp_processor_id();
+@@ -52,7 +52,7 @@ asmlinkage __visible void dump_stack(void)
+ if (!was_locked)
+ atomic_set(&dump_lock, -1);
+
+- preempt_enable();
++ migrate_enable();
+ }
+ #else
+ asmlinkage __visible void dump_stack(void)
+--
+2.5.0
+
diff --git a/patches/localversion.patch b/patches/localversion.patch
index b7bd4a96e82b32..2e248fdf122b4e 100644
--- a/patches/localversion.patch
+++ b/patches/localversion.patch
@@ -12,4 +12,4 @@ Link: http://lkml.kernel.org/n/tip-8vdw4bfcsds27cvox6rpb334@git.kernel.org
--- /dev/null
+++ b/localversion-rt
@@ -0,0 +1 @@
-+-rt4
++-rt5
diff --git a/patches/series b/patches/series
index 616e9bfc5e62b5..bdbd1e8462b7f6 100644
--- a/patches/series
+++ b/patches/series
@@ -391,6 +391,7 @@ mm-vmalloc-use-get-cpu-light.patch
block-mq-use-cpu_light.patch
block-mq-drop-preempt-disable.patch
block-mq-don-t-complete-requests-via-IPI.patch
+dump-stack-don-t-disable-preemption-during-trace.patch
# CPU CHILL
rt-introduce-cpu-chill.patch
@@ -556,7 +557,6 @@ i915_compile_fix.patch
drm-i915-drop-trace_i915_gem_ring_dispatch-onrt.patch
i915-bogus-warning-from-i915-when-running-on-PREEMPT.patch
-
cgroups-use-simple-wait-in-css_release.patch
cgroups-scheduling-while-atomic-in-cgroup-code.patch