Subject: Re: wd, disk write cache, sync cache, and softdep.
To: Steven M. Bellovin <smb@research.att.com>
From: Jason Thorpe <thorpej@shagadelic.org>
List: tech-kern
Date: 12/16/2004 13:57:21
--Apple-Mail-10-372990471
Content-Transfer-Encoding: 7bit
Content-Type: text/plain; charset=US-ASCII; format=flowed


On Dec 16, 2004, at 10:35 AM, Steven M. Bellovin wrote:

> But under what conditions should higher layers set this flag?

Consider the case of a journaling file system.

Writes to the journal itself would be issued with FUA set.

As buffers described by the journal are flushed to disk, the journal 
might decide it's time to advance the journal's "producer" pointer 
(journal replay being the "consumer").  Before it does that, it would 
issue a synchronize-cache command to the disk to ensure that all of 
that data is, in fact, on disk.  Then it would update the producer 
pointer.

Those are a couple of examples, anyway.

         -- Jason R. Thorpe <thorpej@shagadelic.org>


--Apple-Mail-10-372990471
content-type: application/pgp-signature; x-mac-type=70674453;
	name=PGP.sig
content-description: This is a digitally signed message part
content-disposition: inline; filename=PGP.sig
content-transfer-encoding: 7bit

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (Darwin)

iD8DBQFBwgTCOpVKkaBm8XkRAmvtAKC0oCdnmLHzOAcz3WZimLtpJZZ8XQCgmbh3
IFk3PrfWK3MiJiW8YyWtJUE=
=2T/+
-----END PGP SIGNATURE-----

--Apple-Mail-10-372990471--