Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

NFS: fix RENAME attr in presence of directory delegations

Since commit 6f9bda2337f8 ("NFS: Fix directory delegation
verifier checks") xfstest generic/309 is failing because after
the rename (mv) operation, client's mtime/ctime is the same.
Update the delegated mtime when directory delegations are
present in rename.

Fixes: 6f9bda2337f8 ("NFS: Fix directory delegation verifier checks")
Signed-off-by: Olga Kornievskaia <okorniev@redhat.com>
Reviewed-by: Benjamin Coddington <bcodding@hammerspace.com>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>

authored by

Olga Kornievskaia and committed by
Trond Myklebust
4fa7ab8d 94545ffc

+3 -1
+2 -1
fs/nfs/inode.c
··· 692 692 693 693 void nfs_update_delegated_mtime_locked(struct inode *inode) 694 694 { 695 - if (nfs_have_delegated_mtime(inode)) 695 + if (nfs_have_delegated_mtime(inode) || 696 + nfs_have_directory_delegation(inode)) 696 697 nfs_update_mtime(inode); 697 698 } 698 699
+1
fs/nfs/nfs4proc.c
··· 5052 5052 res->new_fattr->time_start, 5053 5053 NFS_INO_INVALID_NLINK | 5054 5054 NFS_INO_INVALID_DATA); 5055 + nfs_update_delegated_mtime(new_dir); 5055 5056 } else 5056 5057 nfs4_update_changeattr(old_dir, &res->old_cinfo, 5057 5058 res->old_fattr->time_start,