linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: linux@horizon.com
To: akpm@linux-foundation.org, linux@horizon.com
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, miklos@szeredi.hu
Subject: Re: [patch resend v4] update ctime and mtime for mmaped write
Date: 27 Mar 2007 16:09:33 -0400	[thread overview]
Message-ID: <20070327200933.6321.qmail@science.horizon.com> (raw)
In-Reply-To: <20070327123422.d0bbc064.akpm@linux-foundation.org>

> Suggest you use msync(MS_ASYNC), then
> sync_file_range(SYNC_FILE_RANGE_WAIT_BEFORE|SYNC_FILE_RANGE_WRITE).

Thank you; I didn't know about that.  And I can handle -ENOSYS by falling
back to the old behavior.

> We can fix your application, and we'll break someone else's.

If you can point to an application that it'll break, I'd be a lot more
understanding.  Nobody did, last year.

> I don't think it's solveable, really - the range of applications is so
> broad, and the "standard" is so vague as to be useless.

I agree that standards are sometimes vague, but that one seemed about
as clear as it's possible to be without imposing unreasonably on
the file system and device driver layers.

What part of "The msync() function writes all modified data to
permanent storage locations [...] For mappings to files, the msync()
function ensures that all write operations are completed as defined
for synchronised I/O data integrity completion." suggests that it's not
supposed to do disk I/O?  How is that uselessly vague?

It says to me that msync's raison d'etre is to write data from RAM to
stable storage.  If an application calls it too often, that's
the application's fault just as if it called sync(2) too often.

> This is why we've
> been extending these things with linux-specific goodies which permit
> applications to actually tell the kernel what they want to be done in a
> more finely-grained fashion.

Well, I still think the current Linux behavior is a bug, but there's a
usable (and run-time compatible) workaround that doesn't unreasonably
complicate the code, and that's good enough.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

       reply	other threads:[~2007-03-27 20:09 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20070327123422.d0bbc064.akpm@linux-foundation.org>
2007-03-27 20:09 ` linux [this message]
2007-03-27 20:31   ` Miklos Szeredi
2007-03-28  1:48     ` linux
2007-03-28  7:58       ` Nick Piggin
2007-03-28  9:50         ` linux
2007-03-29  4:59           ` Nick Piggin
2007-03-27 20:47   ` Andrew Morton
2007-03-25 21:10 Miklos Szeredi, Miklos Szeredi
2007-03-26 21:00 ` Andrew Morton
2007-03-26 21:10   ` Matt Mackall
2007-03-26 22:25     ` Andrew Morton
2007-03-26 21:43   ` Miklos Szeredi
2007-03-26 22:31     ` Andrew Morton
2007-03-27  6:55       ` Miklos Szeredi
2007-03-27  7:22         ` Andrew Morton
2007-03-27  7:36           ` Miklos Szeredi
2007-03-27  7:49             ` Andrew Morton
2007-03-27  8:03               ` Miklos Szeredi
2007-03-27  8:18                 ` Andrew Morton
2007-03-27  8:28                   ` Miklos Szeredi
2007-03-27  8:51                     ` Andrew Morton
2007-03-27  9:23                       ` Miklos Szeredi
2007-03-27 17:52                         ` Andrew Morton
2007-03-27 18:29                           ` Miklos Szeredi

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=20070327200933.6321.qmail@science.horizon.com \
    --to=linux@horizon.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=miklos@szeredi.hu \
    /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