The commit is pushed to "branch-rh8-4.18.0-240.1.1.vz8.5.x-ovz" and will appear 
at https://src.openvz.org/scm/ovz/vzkernel.git
after rh8-4.18.0-240.1.1.vz8.5.31
------>
commit 9a546508dde779ebd49a20e0c98fd457d43b770a
Author: Konstantin Khorenko <[email protected]>
Date:   Mon May 24 12:14:24 2021 +0300

    xfs: Allow to mount XFS in non-init userns
    
    At the moment XFS is not marked as ready to be mounted inside non-init
    userns (see xfs_fs_type), while we previously decided to allow using XFS
    inside a CT:
      b86b9049ba50 ("xfs: allow to mount xfs fs inside a Container")
      https://jira.sw.ru/browse/PSBM-72401
    
    so let's mark XFS as mount-able inside non-init userns.
    
    Fixes: b86b9049ba50 ("xfs: allow to mount xfs fs inside a Container")
    https://jira.sw.ru/browse/PSBM-86369
    
    Signed-off-by: Konstantin Khorenko <[email protected]>
    
    eshatokhin@:
    Used FS_VE_MOUNT as suggested by Pavel Tikhomirov (ptikhomirov@) instead
    of FS_USERNS_MOUNT: it is better to allow mounts only from the init
    userns of a container rather than from just any userns.
    
    Cherry-picked from vz7 commit b86b9049ba50 ("xfs: allow to mount xfs fs
    inside a Container")
    
    Done in the scope of https://jira.sw.ru/browse/PSBM-127830.
    Signed-off-by: Evgenii Shatokhin <[email protected]>
---
 fs/xfs/xfs_super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index 482a89720e6d..4841daca2ff2 100644
--- a/fs/xfs/xfs_super.c
+++ b/fs/xfs/xfs_super.c
@@ -1850,7 +1850,7 @@ static struct file_system_type xfs_fs_type = {
        .name                   = "xfs",
        .mount                  = xfs_fs_mount,
        .kill_sb                = kill_block_super,
-       .fs_flags               = FS_REQUIRES_DEV | FS_VIRTUALIZED,
+       .fs_flags               = FS_REQUIRES_DEV | FS_VIRTUALIZED | 
FS_VE_MOUNT,
 };
 MODULE_ALIAS_FS("xfs");
 
_______________________________________________
Devel mailing list
[email protected]
https://lists.openvz.org/mailman/listinfo/devel

Reply via email to