[Top] [All Lists]

Re: [fuse-devel] [PATCH 01/25] VFS: move attr_kill logic from notify_cha

To: Miklos Szeredi <miklos@xxxxxxxxxx>
Subject: Re: [fuse-devel] [PATCH 01/25] VFS: move attr_kill logic from notify_change into helper function
From: Jeff Layton <jlayton@xxxxxxxxxx>
Date: Mon, 6 Aug 2007 14:13:33 -0400
Cc: linux-kernel@xxxxxxxxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, codalist@xxxxxxxxxxxxxxxxxxxxxxxx, cluster-devel@xxxxxxxxxx, jfs-discussion@xxxxxxxxxxxxxxxxxxxxx, mikulas@xxxxxxxxxxxxxxxxxxxxxxxx, zippel@xxxxxxxxxxxxxx, xfs@xxxxxxxxxxx, joel.becker@xxxxxxxxxx, wli@xxxxxxxxxxxxxx, reiserfs-devel@xxxxxxxxxxxxxxx, dhowells@xxxxxxxxxx, fuse-devel@xxxxxxxxxxxxxxxxxxxxx, jffs-dev@xxxxxxxx, user-mode-linux-user@xxxxxxxxxxxxxxxxxxxxx, v9fs-developer@xxxxxxxxxxxxxxxxxxxxx, linux-ext4@xxxxxxxxxxxxxxx, linux-cifs-client@xxxxxxxxxxxxxxx, ocfs2-devel@xxxxxxxxxxxxxx, bfennema@xxxxxxxxxxxxxxxxxxxxxx
In-reply-to: <E1II6cM-0004yj-00@xxxxxxxxxxxxxxxxxxxxxx>
References: <200708061354.l76Ds6sq002260@xxxxxxxxxxxxxxxxxxxx> <E1II6cM-0004yj-00@xxxxxxxxxxxxxxxxxxxxxx>
Sender: xfs-bounce@xxxxxxxxxxx
On Mon, 06 Aug 2007 19:43:46 +0200
Miklos Szeredi <miklos@xxxxxxxxxx> wrote:

> > Separate the handling of the local ia_valid bitmask from the one in
> > attr->ia_valid. This allows us to hand off the actual handling of the
> > ATTR_KILL_* flags to the .setattr i_op when one is defined.
> > 
> > notify_change still needs to process those flags for the local ia_valid
> > variable, since it uses that to decide whether to return early, and to pass
> > a (hopefully) appropriate bitmask to fsnotify_change.
> I agree with this change and fuse will make use of it as well.
> Maybe instead of unconditionally moving attr_kill_to_mode() inside
> ->setattr() it could be made conditional based on an inode flag
> similarly to S_NOCMTIME.  Advantages:
>  - no need to modify a lot of in-tree filesystems
>  - no silent breakage of out-of-tree fs
> Actually I think the new flag would be used by exacly the same
> filesystems as S_NOCMTIME, so maybe it would make sense to rename
> S_NOCMTIME to something more generic (S_NOATTRUPDATE or whatever) and
> use that.
> But that could still break out-of-tree fs, so a separate flag is
> probably better.

In the past I've been told that adding new flags is something of a
"last resort". Since it's not strictly necessary to fix this then
it may be best to avoid that.

That said, if the concensus is that we need a transition mechanism,
then I'd be open to such a suggestion.

Jeff Layton <jlayton@xxxxxxxxxx>

<Prev in Thread] Current Thread [Next in Thread>