Commit f148337b authored by Li Lingfeng's avatar Li Lingfeng
Browse files

Revert "nfs: fix the loss of superblock's initialized flags"

hulk inclusion
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/IBNEQX



--------------------------------

This reverts commit 0a5788bb.

Since flags passed by users can not be set to fc->sb_flags, check of
fc->sb_flags in nfs_compare_mount_options is useless.
The second mount may get the superblock of the first mount since
nfs_compare_mount_options will return true, resulting the change of
s_flags.
Revert this patch and fix the origin issue later.

Fixes: 0a5788bb ("nfs: fix the loss of superblock's initialized flags")
Signed-off-by: default avatarLi Lingfeng <lilingfeng3@huawei.com>
parent 33c097cb
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -254,7 +254,7 @@ struct dentry *nfs4_try_mount(int flags, const char *dev_name,
	res = nfs_follow_remote_path(root_mnt, export_path);

	if (!IS_ERR(res))
		res->d_sb->s_flags |= (flags & SB_RDONLY);
		res->d_sb->s_flags = flags;
	dfprintk(MOUNT, "<-- nfs4_try_mount() = %d%s\n",
		 PTR_ERR_OR_ZERO(res),
		 IS_ERR(res) ? " [error]" : "");