aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/cgroup/cgroup_util.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2022-01-06 11:02:29 -1000
committerTejun Heo <tj@kernel.org>2022-01-06 11:02:29 -1000
commitb09c2baa56347ae65795350dfcc633dedb1c2970 (patch)
treedd0892d5d609933a5f5f6660fffe8e8555dd119e /tools/testing/selftests/cgroup/cgroup_util.c
parentcgroup: Use open-time cgroup namespace for process migration perm checks (diff)
downloadlinux-dev-b09c2baa56347ae65795350dfcc633dedb1c2970.tar.xz
linux-dev-b09c2baa56347ae65795350dfcc633dedb1c2970.zip
selftests: cgroup: Make cg_create() use 0755 for permission instead of 0644
0644 is an odd perm to create a cgroup which is a directory. Use the regular 0755 instead. This is necessary for euid switching test case. Reviewed-by: Michal Koutný <mkoutny@suse.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to '')
-rw-r--r--tools/testing/selftests/cgroup/cgroup_util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/cgroup/cgroup_util.c b/tools/testing/selftests/cgroup/cgroup_util.c
index 623cec04ad42..0cf7e90c0052 100644
--- a/tools/testing/selftests/cgroup/cgroup_util.c
+++ b/tools/testing/selftests/cgroup/cgroup_util.c
@@ -221,7 +221,7 @@ int cg_find_unified_root(char *root, size_t len)
int cg_create(const char *cgroup)
{
- return mkdir(cgroup, 0644);
+ return mkdir(cgroup, 0755);
}
int cg_wait_for_proc_count(const char *cgroup, int count)