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: <20110608194040.GF2324@linux.vnet.ibm.com>
Date:	Wed, 8 Jun 2011 12:40:40 -0700
From:	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
To:	Frederic Weisbecker <fweisbec@...il.com>
Cc:	LKML <linux-kernel@...r.kernel.org>, Ingo Molnar <mingo@...e.hu>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>
Subject: Re: [PATCH 3/4] sched: Make sleeping inside spinlock detection
 working in !CONFIG_PREEMPT

On Wed, Jun 08, 2011 at 07:48:34PM +0200, Frederic Weisbecker wrote:
> Select CONFIG_PREEMPT_COUNT when we enable the sleeping inside
> spinlock detection, so that the preempt offset gets correctly
> incremented/decremented from preempt_disable()/preempt_enable().
> 
> This makes the preempt count eventually working in !CONFIG_PREEMPT
> when that debug option is set and thus fixes the detection of explicit
> preemption disabled sections under such config. Code that sleeps
> in explicitly preempt disabled section can be finally spotted
> in non-preemptible kernels.
> 
> Signed-off-by: Frederic Weisbecker <fweisbec@...il.com>
> Cc: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>

Acked-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>

> Cc: Ingo Molnar <mingo@...e.hu>
> Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>
> ---
>  lib/Kconfig.debug |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
> index 28afa4c..a7dd7b5 100644
> --- a/lib/Kconfig.debug
> +++ b/lib/Kconfig.debug
> @@ -650,6 +650,7 @@ config TRACE_IRQFLAGS
> 
>  config DEBUG_SPINLOCK_SLEEP
>  	bool "Spinlock debugging: sleep-inside-spinlock checking"
> +	select PREEMPT_COUNT
>  	depends on DEBUG_KERNEL
>  	help
>  	  If you say Y here, various routines which may sleep will become very
> -- 
> 1.7.5.4
> 
--
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