[Devel] [PATCH RHEL7 COMMIT] sysfs/ve: fix output cgroup/ve/ve.default_sysfs_permissions

Konstantin Khorenko khorenko at virtuozzo.com
Fri Mar 22 18:43:33 MSK 2019


The commit is pushed to "branch-rh7-3.10.0-957.10.1.vz7.85.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-957.10.1.vz7.85.2
------>
commit 58ba2bcab691e701dea94a8e6bc8fb7e95fb9ea1
Author: Andrey Ryabinin <aryabinin at virtuozzo.com>
Date:   Fri Mar 22 18:43:31 2019 +0300

    sysfs/ve: fix output cgroup/ve/ve.default_sysfs_permissions
    
    sysfs_perms_open() replaces ve0 with NULL which results in always empty
    output from cgroup/ve/ve.default_sysfs_permissions file.
    
    Fix that by passing correct ve0 address.
    
    Fixes: 7ce278f50962 ("ve/sysfs: add dentries visibility filter")
    Signed-off-by: Andrey Ryabinin <aryabinin at virtuozzo.com>
---
 fs/sysfs/ve.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/sysfs/ve.c b/fs/sysfs/ve.c
index 1e8abec8296b..ea89e41d4b9e 100644
--- a/fs/sysfs/ve.c
+++ b/fs/sysfs/ve.c
@@ -111,7 +111,7 @@ static int sysfs_perms_open(struct inode *inode, struct file *file)
 	ret = seq_open(file, &sysfs_perms_sops);
 	if (!ret) {
 		m = file->private_data;
-		m->private = ve_is_super(ve) ? NULL : ve;
+		m->private = ve;
 	}
 	return ret;
 }



More information about the Devel mailing list