public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Stephen C. Tweedie" <sct@redhat.com>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Stephen Tweedie <sct@redhat.com>,
	linux-fsdevel@vger.kernel.org
Subject: Re: Linux-2.4.0-test10
Date: Thu, 2 Nov 2000 17:17:17 +0000	[thread overview]
Message-ID: <20001102171717.L1876@redhat.com> (raw)
In-Reply-To: <Pine.LNX.4.10.10010311237430.22165-100000@penguin.transmeta.com> <E13qiR9-0008FT-00@the-village.bc.nu>
In-Reply-To: <E13qiR9-0008FT-00@the-village.bc.nu>; from alan@lxorguk.ukuu.org.uk on Tue, Oct 31, 2000 at 08:55:13PM +0000

Hi,

On Tue, Oct 31, 2000 at 08:55:13PM +0000, Alan Cox wrote:
> 
> Questions:
> 	Has the O_SYNC stuff been fixed so that more than ext2 honours this
> 	flag ?

Not yet.

Linus, the last patch I sent you on this didn't make it in --- is it
worth my while resending, or do we need to rethink how to do this?

2.2 O_SYNC is actually broken too --- it doesn't sync all metadata (in
particular, it doesn't update the inode), but I'd rather fix that for
2.4 rather than change 2.2, as the main users of O_SYNC, databases,
are writing to preallocated files anyway.

The patch I sent fully implements O_SYNC (actually, it implements
O_DSYNC, which is allowed to skip the inode sync if the only attribute
which has changed is the timestamps) and fdatasync.  It's easy for me
to make the DSYNC selectable via sysctl for full SU compliance, and I
know of other unixes that already do this --- you really don't want
existing database applications suddenly to start seeking to the inode
block for every O_SYNC write.

There are two parts to the implementation here --- the separation of
O_DIRTY into two bits, a "fully-dirty" bit and a "timestamp-dirty"
bit, and the use of a linked list of buffer_heads against each inode
to track all dirty data.  It is possible to do without the latter, but
that requires either doing a full mapping tree walk after O_SYNC to
flush indirect blocks, or doing indirect writes synchronously as we
write out the data.  f[data]sync can't do the sync-indirect-write
trick, so is still required to walk the whole indirect tree on fsync,
which can get expensive on large files.

Cheers,
 Stephen
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

  parent reply	other threads:[~2000-11-02 17:21 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-10-31 20:41 Linux-2.4.0-test10 Linus Torvalds
2000-10-31 20:48 ` Linux-2.4.0-test10 Rik van Riel
2000-10-31 20:57   ` Linux-2.4.0-test10 Linus Torvalds
2000-11-01  5:40     ` Linux-2.4.0-test10 adrian
2000-10-31 20:55 ` Linux-2.4.0-test10 Alan Cox
2000-11-01  1:35   ` Linux-2.4.0-test10 Paul Jakma
2000-11-01  3:53   ` Linux-2.4.0-test10 Jeremy Fitzhardinge
2000-11-01  8:38   ` Linux-2.4.0-test10 Andi Kleen
2000-11-01 18:08     ` Linux-2.4.0-test10 kuznet
2000-11-02  0:03     ` Linux-2.4.0-test10 Jeff Garzik
2000-11-01 23:52       ` Linux-2.4.0-test10 David S. Miller
2000-11-02 17:17   ` Stephen C. Tweedie [this message]
2000-11-02 17:36     ` Linux-2.4.0-test10 Christoph Rohland
2000-11-03 19:18     ` Linux-2.4.0-test10 Pavel Machek
2000-11-04 18:49     ` Linux-2.4.0-test10 Marco d'Itri
2000-11-05  1:44       ` Linux-2.4.0-test10 H. Peter Anvin
2000-11-06 12:55       ` Linux-2.4.0-test10 Stephen C. Tweedie
2000-11-09 16:45       ` Linux-2.4.0-test10 Stephen C. Tweedie
2000-11-01  2:18 ` Linux-2.4.0-test10 Tom Rini
2000-11-01  5:46 ` Linux-2.4.0-test10 Miles Lane
2000-11-01  5:43   ` Linux-2.4.0-test10 Linus Torvalds
2000-11-01 10:19 ` Linux-2.4.0-test10 Tigran Aivazian
2000-11-01 15:01   ` Linux-2.4.0-test10 Alan Cox
2000-11-01 15:19     ` Linux-2.4.0-test10 Tigran Aivazian
  -- strict thread matches above, loose matches on Subject: below --
2000-11-01  6:03 Linux-2.4.0-test10 M.H.VanLeeuwen
2000-11-01 19:28 ` Linux-2.4.0-test10 David Ford
2000-11-02  0:08   ` Linux-2.4.0-test10 M.H.VanLeeuwen
2000-11-02  2:57     ` Linux-2.4.0-test10 David Ford
2000-11-02  7:15 ` Linux-2.4.0-test10 Vitezslav Samel
2000-11-01 12:51 Linux-2.4.0-test10 Mikael Pettersson
2000-11-01 16:12 Linux-2.4.0-test10 CRADOCK, Christopher
2000-11-02  0:44 ` Linux-2.4.0-test10 M.H.VanLeeuwen
2000-11-02 17:57   ` Linux-2.4.0-test10 Ragnar Hojland Espinosa
2000-11-02 18:38     ` Linux-2.4.0-test10 Ragnar Hojland Espinosa
2000-11-03  6:25       ` Linux-2.4.0-test10 kernel
2000-11-03 10:02         ` Linux-2.4.0-test10 Ben Ford
2000-11-07 10:22         ` Linux-2.4.0-test10 Ragnar Hojland Espinosa
2000-11-07 18:39           ` Linux-2.4.0-test10 Zephaniah E. Hull
2000-11-03  7:08 ` Linux-2.4.0-test10 James Simmons
2000-11-02 18:46 Linux-2.4.0-test10 CRADOCK, Christopher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20001102171717.L1876@redhat.com \
    --to=sct@redhat.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox