> > You can replace the inode in ->create_open() if you want to. > > Thinking a bit more clearly after a cup of coffee. This statement isn't > even true. > > Your pseudo-code offers no guarantees that you are the sole user of the > dentry once you get to create_open(). You are right. I meant, replace the dentry. > > Or let the VFS redo the lookup (as if d_revalidate() returned 0). > > Which may return yet another result for the dentry and another race. > There is no guarantee that you will ever make progress if someone is > doing something like. > > while true > do > echo "1" > foo > echo "2" > foo > done > > on the server. Not good example. This won't change the file, only the contents. Something with rename would be better. We are still pitting two different races against each other. I can't see such a big difference in ugliness... Miklos - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- References:
- [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- Re: [RFC] atomic create+open
- From: Miklos Szeredi <[email protected]>
- Re: [RFC] atomic create+open
- From: Trond Myklebust <[email protected]>
- [RFC] atomic create+open
- Prev by Date: Re: [PATCH] Fix hotplug cpu on x86_64
- Next by Date: Re: [2.6] binfmt_elf bug (exposed by klibc).
- Previous by thread: Re: [RFC] atomic create+open
- Next by thread: Re: [RFC] atomic create+open
- Index(es):