fuse: only update necessary attributes
authorMiklos Szeredi <mszeredi@redhat.com>
Fri, 22 Oct 2021 15:03:03 +0000 (17:03 +0200)
committerMiklos Szeredi <mszeredi@redhat.com>
Thu, 28 Oct 2021 07:45:33 +0000 (09:45 +0200)
commitc6c745b81033a4c1f0e5f3b16398a10f2d000c29
tree5f4c90689a9e891a43b79a97d862221dece1ce9c
parentec85537519b330a0deb8fe742fd1b0efc40a1710
fuse: only update necessary attributes

fuse_update_attributes() refreshes metadata for internal use.

Each use needs a particular set of attributes to be refreshed, but
currently that cannot be expressed and all but atime are refreshed.

Add a mask argument, which lets fuse_update_get_attr() to decide based on
the cache_mask and the inval_mask whether a GETATTR call is needed or not.

Reported-by: Yongji Xie <xieyongji@bytedance.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
fs/fuse/dir.c
fs/fuse/file.c
fs/fuse/fuse_i.h
fs/fuse/readdir.c