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]
Date:	Tue, 08 Feb 2011 17:55:27 +0100
From:	Peter Zijlstra <peterz@...radead.org>
To:	Yong Zhang <yong.zhang0@...il.com>
Cc:	Nick Bowler <nbowler@...iptictech.com>,
	linux-kernel@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	Steven Rostedt <rostedt@...dmis.org>
Subject: Re: Regression: WARNINGS and lockdep spews in 2.6.38-rc3+
 (bisected).

On Thu, 2011-02-03 at 19:42 +0800, Yong Zhang wrote:
> My patch is inspired by this http://lkml.org/lkml/2010/8/16/291

Right, so that splat warns about:

spin_lock_irqsave(&shost->host_lock);
del_timer_sync()
  spin_lock_irqsave(&t->split_timeout_timer);

vs

<SOFTIRQ>
  call_timer_fn()
    spin_lock(&t->split_timeout_timer);
    <IRQ>
      spin_lock_irqsave(&shost->host_lock);

Which Steven just pointed out is an actual deadlock because:


CPU0					CPU1
spin_lock_irqsave(&shost->host_lock);
					<SOFTIRQ>
					  call_timer_fn();
					    base->running_timer = timer;
					    func();
					      <IRQ>
						spin_lock(&shost->host_lock);
del_timer_sync()
  while(base->running_timer == timer);

And the world stops turning..


Also note that your patch changes the above to:

spin_lock_irqsave(&shost->host_lock);
del_timer_sync()
  spin_lock_bh(&t->split_timeout_timer);

Which wouldn't make one bit of difference.

--
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