-
由 Dave Chinner 提交于
mainline inclusion from mainline-v5.14-rc4 commit 2e973b2c category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I4KIAO CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=2e973b2cd4cdb993be94cca4c33f532f1ed05316 -------------------------------- The remaining mount flags kept in m_flags are actually runtime state flags. These change dynamically, so they really should be updated atomically so we don't potentially lose an update due to racing modifications. Convert these remaining flags to be stored in m_opstate and use atomic bitops to set and clear the flags. This also adds a couple of simple wrappers for common state checks - read only and shutdown. Signed-off-by: NDave Chinner <dchinner@redhat.com> Reviewed-by: NDarrick J. Wong <djwong@kernel.org> Signed-off-by: NDarrick J. Wong <djwong@kernel.org> Conflicts: fs/xfs/xfs_mount.c fs/xfs/xfs_super.c Signed-off-by: NLong Li <leo.lilong@huawei.com>
19e16281