Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1242678 > unrolled thread
| Started by | Daniel Bristot de Oliveira <bristot@redhat.com> |
|---|---|
| First post | 2015-10-08 20:40 +0200 |
| Last post | 2015-10-12 10:00 +0200 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH] trace: stop critical timings before idle loop on idle=poll Daniel Bristot de Oliveira <bristot@redhat.com> - 2015-10-08 20:40 +0200
Re: [PATCH] trace: stop critical timings before idle loop on idle=poll Steven Rostedt <rostedt@goodmis.org> - 2015-10-09 18:40 +0200
[tip:sched/urgent] sched, tracing: Stop/ start critical timings around the idle=poll idle loop tip-bot for Daniel Bristot de Oliveira <tipbot@zytor.com> - 2015-10-12 10:00 +0200
| From | Daniel Bristot de Oliveira <bristot@redhat.com> |
|---|---|
| Date | 2015-10-08 20:40 +0200 |
| Subject | [PATCH] trace: stop critical timings before idle loop on idle=poll |
| Message-ID | <qhogF-3ew-3@gated-at.bofh.it> |
When using idle=poll, the preemptoff tracer is always showing the idle task as the culprit for long latencies. That happens because critical timings are not stopped before idle loop. This patch stops critical timings before entering the idle loop, starting it again after the idle loop. This problem does not affect the irqsoff tracer because interruptions are enabled before entering the idle loop. Signed-off-by: Daniel Bristot de Oliveira <bristot@redhat.com> Reviewed-by: Luis Claudio R. Goncalves <lgoncalv@redhat.com> --- kernel/sched/idle.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kernel/sched/idle.c b/kernel/sched/idle.c index 8f177c7..4a2ef5a 100644 --- a/kernel/sched/idle.c +++ b/kernel/sched/idle.c @@ -57,9 +57,11 @@ static inline int cpu_idle_poll(void) rcu_idle_enter(); trace_cpu_idle_rcuidle(0, smp_processor_id()); local_irq_enable(); + stop_critical_timings(); while (!tif_need_resched() && (cpu_idle_force_poll || tick_check_broadcast_expired())) cpu_relax(); + start_critical_timings(); trace_cpu_idle_rcuidle(PWR_EVENT_EXIT, smp_processor_id()); rcu_idle_exit(); return 1; -- 2.4.3 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Steven Rostedt <rostedt@goodmis.org> |
|---|---|
| Date | 2015-10-09 18:40 +0200 |
| Subject | Re: [PATCH] trace: stop critical timings before idle loop on idle=poll |
| Message-ID | <qhIS7-7BS-31@gated-at.bofh.it> |
| In reply to | #1242678 |
On Thu, 8 Oct 2015 15:36:06 -0300 Daniel Bristot de Oliveira <bristot@redhat.com> wrote: > When using idle=poll, the preemptoff tracer is always showing the idle > task as the culprit for long latencies. That happens because critical > timings are not stopped before idle loop. This patch stops critical > timings before entering the idle loop, starting it again after the > idle loop. > > This problem does not affect the irqsoff tracer because interruptions > are enabled before entering the idle loop. > > Signed-off-by: Daniel Bristot de Oliveira <bristot@redhat.com> > Reviewed-by: Luis Claudio R. Goncalves <lgoncalv@redhat.com> Acked-by: Steven Rostedt <rostedt@goodmis.org> -- Steve > --- > kernel/sched/idle.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/kernel/sched/idle.c b/kernel/sched/idle.c > index 8f177c7..4a2ef5a 100644 > --- a/kernel/sched/idle.c > +++ b/kernel/sched/idle.c > @@ -57,9 +57,11 @@ static inline int cpu_idle_poll(void) > rcu_idle_enter(); > trace_cpu_idle_rcuidle(0, smp_processor_id()); > local_irq_enable(); > + stop_critical_timings(); > while (!tif_need_resched() && > (cpu_idle_force_poll || tick_check_broadcast_expired())) > cpu_relax(); > + start_critical_timings(); > trace_cpu_idle_rcuidle(PWR_EVENT_EXIT, smp_processor_id()); > rcu_idle_exit(); > return 1; -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | tip-bot for Daniel Bristot de Oliveira <tipbot@zytor.com> |
|---|---|
| Date | 2015-10-12 10:00 +0200 |
| Subject | [tip:sched/urgent] sched, tracing: Stop/ start critical timings around the idle=poll idle loop |
| Message-ID | <qiGbx-Yi-17@gated-at.bofh.it> |
| In reply to | #1242678 |
Commit-ID: 9babcd7929bc8967ae3bb6093f603b93c2f9958f Gitweb: http://git.kernel.org/tip/9babcd7929bc8967ae3bb6093f603b93c2f9958f Author: Daniel Bristot de Oliveira <bristot@redhat.com> AuthorDate: Thu, 8 Oct 2015 15:36:06 -0300 Committer: Ingo Molnar <mingo@kernel.org> CommitDate: Mon, 12 Oct 2015 09:45:25 +0200 sched, tracing: Stop/start critical timings around the idle=poll idle loop When using idle=poll, the preemptoff tracer is always showing the idle task as the culprit for long latencies. That happens because critical timings are not stopped before idle loop. This patch stops critical timings before entering the idle loop, starting it again after the idle loop. This problem does not affect the irqsoff tracer because interruptions are enabled before entering the idle loop. Signed-off-by: Daniel Bristot de Oliveira <bristot@redhat.com> Reviewed-by: Luis Claudio R. Goncalves <lgoncalv@redhat.com> Acked-by: Steven Rostedt <rostedt@goodmis.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/10fc3705874aef11dbe152a068b591a7be1899b4.1444314899.git.bristot@redhat.com Signed-off-by: Ingo Molnar <mingo@kernel.org> --- kernel/sched/idle.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kernel/sched/idle.c b/kernel/sched/idle.c index 8f177c7..4a2ef5a 100644 --- a/kernel/sched/idle.c +++ b/kernel/sched/idle.c @@ -57,9 +57,11 @@ static inline int cpu_idle_poll(void) rcu_idle_enter(); trace_cpu_idle_rcuidle(0, smp_processor_id()); local_irq_enable(); + stop_critical_timings(); while (!tif_need_resched() && (cpu_idle_force_poll || tick_check_broadcast_expired())) cpu_relax(); + start_critical_timings(); trace_cpu_idle_rcuidle(PWR_EVENT_EXIT, smp_processor_id()); rcu_idle_exit(); return 1; -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web