mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Trond Myklebust <trond.myklebust@fys.uio.no>
To: Bryan Henderson <hbryan@us.ibm.com>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	Miklos Szeredi <miklos@szeredi.hu>
Subject: Re: [RFC] atomic open(..., O_CREAT | ...)
Date: Tue, 09 Aug 2005 12:07:41 -0400	[thread overview]
Message-ID: <1123603661.8245.78.camel@lade.trondhjem.org> (raw)
In-Reply-To: <OF8B842185.9331BF0D-ON88257058.0054CAEE-88257058.0056B6B6@us.ibm.com>

ty den 09.08.2005 Klokka 08:47 (-0700) skreiv Bryan Henderson:
> >Intents are meant as optimisations, not replacements for existing
> >operations. I'm therefore not really comfortable about having them
> >return errors at all.
> 
> That's true of normal intents, but not what are called intents here.  A 
> normal intent merely expresses an intent, and it can be totally ignored 
> without harm to correctness.  But these "intents" were designed to be 
> responded to by actually performing the foreshadowed operation now - 
> irreversibly.
> 
> Linux needs an atomic lookup/open/create in order to participate in a 
> shared filesystem and provide a POSIX interface (where shared filesystem 
> means a filesystem that is simultaneously accessed by something besides 
> the Linux system in question).  Some operating systems do this simply with 
> a VFS lookup/open/create function.  Linux does it with this intents 
> interface.
> 
> It's hard to merge the concepts in code or in one's mind, which is why 
> we're here now.  A filesystem driver that needs to do atomic 
> lookup/open/create has to bend over backwards to split the operation 
> across the three filesystem driver calls that Linux wants to make.
> 
> I've always preferred just to have a new inode operation for 
> lookup/open/create (mirroring the POSIX open operation, used for all opens 
> if available), but if enough arguments to lookup can do it, that's 
> practically as good.  But that means returning final status from lookup, 
> and not under any circumstance proceeding to create or open when the 
> filesystem driver has said the entire operation is complete.

Have you looked at how we're dealing with this in NFSv4?

Cheers,
  Trond


  reply	other threads:[~2005-08-09 16:08 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-08 22:27 Miklos Szeredi
2005-08-08 22:58 ` Trond Myklebust
2005-08-09  7:46   ` Miklos Szeredi
2005-08-09 13:34     ` Trond Myklebust
2005-08-09 15:47       ` Bryan Henderson
2005-08-09 16:07         ` Trond Myklebust [this message]
2005-08-09 16:34           ` Bryan Henderson
2005-08-09 16:40       ` Miklos Szeredi
2005-08-09 17:18         ` Trond Myklebust
2005-08-09 17:44           ` Miklos Szeredi
2005-08-09 18:38             ` Trond Myklebust
2005-08-09 20:42               ` Miklos Szeredi
2005-08-09 21:11                 ` Trond Myklebust
2005-08-09 21:19                   ` 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=1123603661.8245.78.camel@lade.trondhjem.org \
    --to=trond.myklebust@fys.uio.no \
    --cc=hbryan@us.ibm.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®