Skip to content

Commit 9d9d341

Browse files
rgushchintorvalds
authored andcommitted
cgroup: remove obsoleted broken_hierarchy and warned_broken_hierarchy
With the deprecation of the non-hierarchical mode of the memory controller there are no more examples of broken hierarchies left. Let's remove the cgroup core code which was supposed to print warnings about creating of broken hierarchies. Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Roman Gushchin <[email protected]> Reviewed-by: Shakeel Butt <[email protected]> Acked-by: David Rientjes <[email protected]> Acked-by: Johannes Weiner <[email protected]> Cc: Michal Hocko <[email protected]> Cc: Tejun Heo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent 1842186 commit 9d9d341

File tree

2 files changed

+0
-22
lines changed

2 files changed

+0
-22
lines changed

include/linux/cgroup-defs.h

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -668,21 +668,6 @@ struct cgroup_subsys {
668668
*/
669669
bool threaded:1;
670670

671-
/*
672-
* If %false, this subsystem is properly hierarchical -
673-
* configuration, resource accounting and restriction on a parent
674-
* cgroup cover those of its children. If %true, hierarchy support
675-
* is broken in some ways - some subsystems ignore hierarchy
676-
* completely while others are only implemented half-way.
677-
*
678-
* It's now disallowed to create nested cgroups if the subsystem is
679-
* broken and cgroup core will emit a warning message on such
680-
* cases. Eventually, all subsystems will be made properly
681-
* hierarchical and this will go away.
682-
*/
683-
bool broken_hierarchy:1;
684-
bool warned_broken_hierarchy:1;
685-
686671
/* the following two fields are initialized automtically during boot */
687672
int id;
688673
const char *name;

kernel/cgroup/cgroup.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5149,13 +5149,6 @@ static struct cgroup_subsys_state *css_create(struct cgroup *cgrp,
51495149
if (err)
51505150
goto err_list_del;
51515151

5152-
if (ss->broken_hierarchy && !ss->warned_broken_hierarchy &&
5153-
cgroup_parent(parent)) {
5154-
pr_warn("%s (%d) created nested cgroup for controller \"%s\" which has incomplete hierarchy support. Nested cgroups may change behavior in the future.\n",
5155-
current->comm, current->pid, ss->name);
5156-
ss->warned_broken_hierarchy = true;
5157-
}
5158-
51595152
return css;
51605153

51615154
err_list_del:

0 commit comments

Comments
 (0)