lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20151009123830.03b4cb5c@gandalf.local.home>
Date:	Fri, 9 Oct 2015 12:38:30 -0400
From:	Steven Rostedt <rostedt@...dmis.org>
To:	Daniel Bristot de Oliveira <bristot@...hat.com>
Cc:	Peter Zijlstra <peterz@...radead.org>,
	Ingo Molnar <mingo@...hat.com>,
	LKML <linux-kernel@...r.kernel.org>,
	"Luis Claudio R. Goncalves" <lgoncalv@...hat.com>
Subject: Re: [PATCH] trace: stop critical timings before idle loop on
 idle=poll

On Thu,  8 Oct 2015 15:36:06 -0300
Daniel Bristot de Oliveira <bristot@...hat.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@...hat.com>
> Reviewed-by: Luis Claudio R. Goncalves <lgoncalv@...hat.com>

Acked-by: Steven Rostedt <rostedt@...dmis.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@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ