[lkml]   [2004]   [Mar]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] barrier patch set
On Sat, 2004-03-20 at 11:23, Bartlomiej Zolnierkiewicz wrote:

> > > - why are we doing pre-flush?
> >
> > To ensure previously written data is on platter first.
> I know this, I want to know what for you are doing this?
> Previously written data is already acknowledgment to the upper layers so you
> can't do much even if you hit error on flush cache. IMO if error happens we
> should just check if failed sector is of our ordered write if not well report
> it and continue. It's cleaner and can give some (small?) performance gain.

The journaled filesystems need this. We need to make sure that before
we write the commit block for a transaction, all the previous log blocks
we're written are safely on media. Then we also need to make sure the
commit block is on media.

We end up with a log blocks, pre-flush, commit block, post-flush cycle,
which is what gives the proper transaction ordering on disk.

For data blocks we only need the post flush, which is why Jens made
blkdev_issue_flush skip the pre-flush.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 14:01    [W:0.075 / U:2.940 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site