aboutsummaryrefslogtreecommitdiff
path: root/scripts/gcc-plugins/cyc_complexity_plugin.c
diff options
context:
space:
mode:
authorChristian Brauner <[email protected]>2020-02-05 14:26:18 +0100
committerTejun Heo <[email protected]>2020-02-12 17:57:51 -0500
commit6df970e4f5d2c273554550d40d8b92cea9bec1a0 (patch)
treea7734ff12f7dbb720c60a80c4b4519cb2d6b2809 /scripts/gcc-plugins/cyc_complexity_plugin.c
parenta49e4629b5edf1db856de05fbf1aae05502ef1af (diff)
cgroup: unify attach permission checking
The core codepaths to check whether a process can be attached to a cgroup are the same for threads and thread-group leaders. Only a small piece of code verifying that source and destination cgroup are in the same domain differentiates the thread permission checking from thread-group leader permission checking. Since cgroup_migrate_vet_dst() only matters cgroup2 - it is a noop on cgroup1 - we can move it out of cgroup_attach_task(). All checks can now be consolidated into a new helper cgroup_attach_permissions() callable from both cgroup_procs_write() and cgroup_threads_write(). Cc: Tejun Heo <[email protected]> Cc: Li Zefan <[email protected]> Cc: Johannes Weiner <[email protected]> Cc: [email protected] Acked-by: Michal Koutný <[email protected]> Signed-off-by: Christian Brauner <[email protected]> Signed-off-by: Tejun Heo <[email protected]>
Diffstat (limited to 'scripts/gcc-plugins/cyc_complexity_plugin.c')
0 files changed, 0 insertions, 0 deletions