
hulk inclusion category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/IBNEQX -------------------------------- This reverts commit ed901d64fb8bbdeadabbda2924fc30a89ffa6ebc. 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: ed901d64fb8b ("nfs: ignore SB_RDONLY when mounting nfs") Signed-off-by: Li Lingfeng <lilingfeng3@huawei.com> --- fs/nfs/internal.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/nfs/internal.h b/fs/nfs/internal.h index 44ca5300e6e2..10572e9f6d88 100644 --- a/fs/nfs/internal.h +++ b/fs/nfs/internal.h @@ -10,7 +10,7 @@ #include <linux/nfs_page.h> #include <linux/wait_bit.h> -#define NFS_MS_MASK (SB_NOSUID|SB_NODEV|SB_NOEXEC|SB_SYNCHRONOUS) +#define NFS_MS_MASK (SB_RDONLY|SB_NOSUID|SB_NODEV|SB_NOEXEC|SB_SYNCHRONOUS) extern const struct export_operations nfs_export_ops; -- 2.31.1