fs/9p: Remove unnecessary superblock flags
authorEric Van Hensbergen <ericvh@kernel.org>
Sat, 17 Dec 2022 17:05:47 +0000 (17:05 +0000)
committerEric Van Hensbergen <ericvh@kernel.org>
Mon, 27 Mar 2023 02:33:47 +0000 (02:33 +0000)
These flags just add unnecessary extra operations.
When 9p is run without cache, it inherently implements
these options so we don't need them in the superblock
(which ends up sending extraneous fsyncs, etc.).  User
can still request these options on mount, but we don't
need to set them as default.

Signed-off-by: Eric Van Hensbergen <ericvh@kernel.org>
fs/9p/vfs_super.c

index 266c4693e20c55c2474d8527f9a8f63ca8c05798..65d96fa94ba228327c6f517a65bb50af64c5af72 100644 (file)
@@ -84,9 +84,7 @@ v9fs_fill_super(struct super_block *sb, struct v9fs_session_info *v9ses,
                sb->s_bdi->io_pages = v9ses->maxdata >> PAGE_SHIFT;
        }
 
-       sb->s_flags |= SB_ACTIVE | SB_DIRSYNC;
-       if (!v9ses->cache)
-               sb->s_flags |= SB_SYNCHRONOUS;
+       sb->s_flags |= SB_ACTIVE;
 
 #ifdef CONFIG_9P_FS_POSIX_ACL
        if ((v9ses->flags & V9FS_ACL_MASK) == V9FS_POSIX_ACL)