All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Chuck Lever" <cel@kernel.org>
To: "Jeff Layton" <jlayton@kernel.org>, NeilBrown <neil@brown.name>,
	"Olga Kornievskaia" <okorniev@redhat.com>,
	"Dai Ngo" <Dai.Ngo@oracle.com>, "Tom Talpey" <tom@talpey.com>,
	"Alexander Viro" <viro@zeniv.linux.org.uk>,
	"Christian Brauner" <brauner@kernel.org>,
	"Jan Kara" <jack@suse.cz>
Cc: "Thomas Haynes" <loghyr@gmail.com>,
	linux-nfs@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH v2 0/3] fs/nfsd: accept a backdated timestamp from a delegation holder
Date: Wed, 02 Sep 2026 20:03:53 -0400	[thread overview]
Message-ID: <3caef4ff-9f01-4b09-8e83-12bcb0a1ee17@app.fastmail.com> (raw)
In-Reply-To: <20260902-delegts-v2-0-383cb289ce88@kernel.org>



On Wed, Sep 2, 2026, at 2:54 PM, Jeff Layton wrote:
> The main problem is that an attribute delegation has strict rules about
> updates can be done, and that prevents applications that backdate
> timestamps on files after writing them, (e.g. tar -x, cp -p, etc.) from
> setting them properly.
>
> We could fix this on the client by making it always issue an RPC for the
> SETATTR, but that would harm performance in these common use-cases.
> This set allows the server to accept some of these backdated mtime
> updates, by changing how the ctime is handled.
>
> It'd be nice to see this in v7.4.
>
> Signed-off-by: Jeff Layton <jlayton@kernel.org>
> ---
> Changes in v2:
> - Split the change into three patches
> - Stamp now in inode_set_ctime_deleg() for a stale update, so nfsd need
>   not compare
> - Drop a SETATTR report that matches the inode, so an untouched file
>   keeps its change attribute
> - Set dl_setattr only on the branch that carries a c/mtime update
> - Compare against the inode, not the grant-time snapshots (Chuck)
> - Set the ctime whenever a CB_GETATTR moves the mtime
> - Take i_rwsem before the CB_GETATTR comparison
> - Drop the unused dl_atime, dl_mtime and dl_ctime, and make
>   nfsd4_vet_deleg_time() static
> - Link to v1: 
> https://lore.kernel.org/r/20260901-delegts-v1-1-9937f7ee4370@kernel.org
>
> ---
> Jeff Layton (3):
>       fs: stamp the current time for a stale delegated ctime update
>       nfsd: accept a backdated timestamp from a delegation holder
>       nfsd: compare CB_GETATTR times against the inode
>
>  fs/inode.c          | 17 +++++++++++----
>  fs/nfsd/nfs4proc.c  | 63 +++++++++++++++++++++++++++++++++++++++++++----------
>  fs/nfsd/nfs4state.c | 49 ++++++++++++++++++++++++++---------------
>  fs/nfsd/state.h     |  8 -------
>  4 files changed, 95 insertions(+), 42 deletions(-)
> ---
> base-commit: ac579868af0c900d8fd9c8cfe9e10db46ccc5a75
> change-id: 20260901-delegts-e91a648f1427
>
> Best regards,
> -- 
> Jeff Layton <jlayton@kernel.org>

Since the series modifies fs/inode.c, Christian will want to take it
through the VFS tree.

Acked-by: Chuck Lever <cel@kernel.org>


-- 
Chuck Lever (Come to NFS bake-a-thon! https://nfsv4bat.org)

  parent reply	other threads:[~2026-09-03  0:04 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-02 18:54 [PATCH v2 0/3] fs/nfsd: accept a backdated timestamp from a delegation holder Jeff Layton
2026-09-02 18:54 ` [PATCH v2 1/3] fs: stamp the current time for a stale delegated ctime update Jeff Layton
2026-09-03  9:37   ` Jan Kara
2026-09-02 18:54 ` [PATCH v2 2/3] nfsd: accept a backdated timestamp from a delegation holder Jeff Layton
2026-09-02 18:54 ` [PATCH v2 3/3] nfsd: compare CB_GETATTR times against the inode Jeff Layton
2026-09-03  0:03 ` Chuck Lever [this message]
2026-09-04 10:30   ` [PATCH v2 0/3] fs/nfsd: accept a backdated timestamp from a delegation holder Christian Brauner
2026-09-04 10:50 ` Christian Brauner
2026-09-04 11:10   ` Jeff Layton

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=3caef4ff-9f01-4b09-8e83-12bcb0a1ee17@app.fastmail.com \
    --to=cel@kernel.org \
    --cc=Dai.Ngo@oracle.com \
    --cc=brauner@kernel.org \
    --cc=jack@suse.cz \
    --cc=jlayton@kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=loghyr@gmail.com \
    --cc=neil@brown.name \
    --cc=okorniev@redhat.com \
    --cc=tom@talpey.com \
    --cc=viro@zeniv.linux.org.uk \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.