Skip to content
Commit e38cf302 authored by Jeff Layton's avatar Jeff Layton
Browse files

fs: only set S_VERSION when updating times if necessary



We only really need to update i_version if someone has queried for it
since we last incremented it. By doing that, we can avoid having to
update the inode if the times haven't changed.

If the times have changed, then we go ahead and forcibly increment the
counter, under the assumption that we'll be going to the storage
anyway, and the increment itself is relatively cheap.

Signed-off-by: default avatarJeff Layton <jlayton@redhat.com>
Reviewed-by: default avatarJan Kara <jack@suse.cz>
parent 3b370b21
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment