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:	Wed, 20 Apr 2016 00:25:17 +0200 (CEST)
From:	Jiri Kosina <jikos@...nel.org>
To:	Eric Wheeler <bcache@...ts.ewheeler.net>
cc:	Kent Overstreet <kent.overstreet@...il.com>,
	linux-bcache@...r.kernel.org, linux-kernel@...r.kernel.org,
	Maciej Piechotka <uzytkownik2@...il.com>
Subject: Re: [PATCH] bcache: bch_writeback_thread() is not freezable

On Tue, 19 Apr 2016, Eric Wheeler wrote:

> > bch_writeback_thread() is calling try_to_freeze(), but that's just an 
> > expensive no-op given the fact that the thread is not marked freezable.
> > 
> > I/O helper kthreads, exactly such as the bcache writeback thread, actually 
> > shouldn't be freezable, because they are potentially necessary for 
> > finalizing the image write-out.
> 
> This is good timing, as Maciej Piechotka just reported a hang when 
> suspending his system.

Could you please point me to the actual report? Thanks.

> What is the proper way to safely support suspend?  Assuming the 
> try_to_freeze() calls are in the right place, should we simply 
> set_freezable() on these kthreads?

Unfortunately, this is really a tricky question; the issue is that frezing 
semantics is rather undefined for kthreads. For starters, please see

	https://lwn.net/Articles/662703/
	http://lkml.org/lkml/2007/4/27/608

I don't belive in freezable kthreads which serve as I/O helpers. Such 
threads simply have to keep going until the image is written out and 
machine powered down.

So I'd like to start with understanding how bcache is preventning suspend. 
Maciej?

Thanks,

-- 
Jiri Kosina
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ