Skip to content

RFC vfs: allow querying i_version via statx

Jeff Layton ceph-devel fstests linux-btrfs linux-ext4 linux-fsdevel linux-nfs linux-xfs 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest4 patches 14 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4vfs: report change attribute in statx for IS_I_VERSION inodesfs/stat.c include/linux/stat.h include/uapi/linux/stat.h +1 more+13 -212 replies
2/4nfs: report the change attribute if requestedfs/nfs/inode.c+3 -00 replies
3/4afs: fill out change attribute in statx repliesfs/afs/inode.c+2 -00 replies
4/4ceph: fill in the change attribute in statx requestsfs/ceph/inode.c+9 -51 reply

Reviews trailers per patch

1 of 4 patches has a Reviewed-by or Acked-by.

PatchXiubo Li
1/4
2/4
3/4
4/4R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [RFC PATCH 0/4] vfs: allow querying i_version via statx

Recently I posted a patch to turn on the i_version counter unconditionally in ext4, and Lukas rightly pointed out that we don't currently have an easy way to validate its functionality. You can fetch it via NFS (and see it in network traces), but there's no way to get to it from userland.

Besides testing, this may also be of use for userland NFS servers, or by any program that wants to accurately check for file changes, and not be subject to mtime granularity problems.

Comments and suggestions welcome. I'm not 100% convinced that this is a great idea, but we've had people ask for it before and it seems like a reasonable thing to provide.

Jeff Layton (4):
vfs: report change attribute in statx for IS_I_VERSION inodes
nfs: report the change attribute if requested
afs: fill out change attribute in statx replies
ceph: fill in the change attribute in statx requests

 fs/afs/inode.c            |  2 ++
 fs/ceph/inode.c           | 14 +++++++++-----
 fs/nfs/inode.c            |  3 +++
 fs/stat.c                 |  7 +++++++
 include/linux/stat.h      |  1 +
 include/uapi/linux/stat.h |  3 ++-
 samples/vfs/test-statx.c  |  4 +++-
 7 files changed, 27 insertions(+), 7 deletions(-)
Signature · 1 line
2.37.1