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: <alpine.LFD.2.00.0903301931230.4093@localhost.localdomain>
Date:	Mon, 30 Mar 2009 19:47:04 -0700 (PDT)
From:	Linus Torvalds <torvalds@...ux-foundation.org>
To:	Ric Wheeler <rwheeler@...hat.com>
cc:	Jens Axboe <jens.axboe@...cle.com>,
	Fernando Luis Vázquez Cao 
	<fernando@....ntt.co.jp>, Jeff Garzik <jeff@...zik.org>,
	Christoph Hellwig <hch@...radead.org>,
	Theodore Tso <tytso@....edu>, Ingo Molnar <mingo@...e.hu>,
	Alan Cox <alan@...rguk.ukuu.org.uk>,
	Arjan van de Ven <arjan@...radead.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Nick Piggin <npiggin@...e.de>, David Rees <drees76@...il.com>,
	Jesper Krogh <jesper@...gh.cc>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	chris.mason@...cle.com, david@...morbit.com, tj@...nel.org
Subject: Re: [PATCH 1/7] block: Add block_flush_device()



On Mon, 30 Mar 2009, Ric Wheeler wrote:
> 
> One thing the caller could do is to disable the write cache on the device.

First off, that's not the callers job. If the sysadmin enabled it, some 
random filesystem shouldn't disable it.

Secondly, this whole insane belief that "write cache" has anything to do 
with "unable to flush" is just bogus. 

> A second would be to stop using the transactions - skip the journal, 
> just go back to ext2 mode or BSD like soft updates.

f*ck me, what's so hard with understanding that EOPNOTSUPP doesn't mean 
"no ordering". It means what it says - the op isn't supported. For all you 
know, ALL WRITES MAY BE TOTALLY ORDERED, but perhaps there is no way to 
make a _single_ write totally atomic (ie the "set barrier on a command 
that actually does IO").

Besides, why the hell do you think the filesystem (again) should do 
something that the admin didn't ask it to do.

If the admin wants the thing to fall back to ext2, then he can ask to 
disable the journal.

> Basically, it lets the file system know that its data integrity building
> blocks are not really there and allows it (if it cares) to try and minimize
> the chance of data loss.

Your whole idiotic "as a filesystem designer I know better than everybody 
else" model where the filesystem is in total control is total crap.

The fact is, it's not the filesystems job to make that decision. If the 
admin wants to have write caching enabled, the filesystem should get the 
hell out of the way.

What about laptop mode? Do you expect your filesystem to always decide 
that "ok, the user wanted to spin down disks, but I know better"?

What about people who have UPS's and don't worry about that part? They 
want write caching on the disk, and simply don't want to sync? They still 
worry about OS crashing, since they run random -git development kernels?

In short, stop this IDIOTIC notion that you know better. YOU DO NOT KNOW 
BETTER. The filesystem DOES NOT KNOW BETTER. It should damn well not do 
those kinds of decisions that are simply not filesystem decisions to make!

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