Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
def2d52b
Unverified
Commit
def2d52b
authored
Apr 10, 2019
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cgfsng: fix cgroup2 handling
Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
3fe0b3cd
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
cgfsng.c
src/lxc/cgroups/cgfsng.c
+4
-5
No files found.
src/lxc/cgroups/cgfsng.c
View file @
def2d52b
...
@@ -2510,8 +2510,9 @@ cleanup_on_err:
...
@@ -2510,8 +2510,9 @@ cleanup_on_err:
static
int
cg_unified_init
(
struct
cgroup_ops
*
ops
)
static
int
cg_unified_init
(
struct
cgroup_ops
*
ops
)
{
{
__do_free
char
*
subtree_path
=
NULL
;
int
ret
;
int
ret
;
char
*
mountpoint
,
*
subtree_path
;
char
*
mountpoint
;
char
**
delegatable
;
char
**
delegatable
;
char
*
base_cgroup
=
NULL
;
char
*
base_cgroup
=
NULL
;
...
@@ -2535,7 +2536,6 @@ static int cg_unified_init(struct cgroup_ops *ops)
...
@@ -2535,7 +2536,6 @@ static int cg_unified_init(struct cgroup_ops *ops)
subtree_path
=
must_make_path
(
mountpoint
,
base_cgroup
,
subtree_path
=
must_make_path
(
mountpoint
,
base_cgroup
,
"cgroup.subtree_control"
,
NULL
);
"cgroup.subtree_control"
,
NULL
);
delegatable
=
cg_unified_get_controllers
(
subtree_path
);
delegatable
=
cg_unified_get_controllers
(
subtree_path
);
free
(
subtree_path
);
if
(
!
delegatable
)
if
(
!
delegatable
)
delegatable
=
cg_unified_make_empty_controller
();
delegatable
=
cg_unified_make_empty_controller
();
if
(
!
delegatable
[
0
])
if
(
!
delegatable
[
0
])
...
@@ -2548,10 +2548,9 @@ static int cg_unified_init(struct cgroup_ops *ops)
...
@@ -2548,10 +2548,9 @@ static int cg_unified_init(struct cgroup_ops *ops)
* controllers per container.
* controllers per container.
*/
*/
add_hierarchy
(
&
ops
->
hierarchies
,
delegatable
,
mountpoint
,
base_cgroup
,
CGROUP2_SUPER_MAGIC
);
ops
->
cgroup_layout
=
CGROUP_LAYOUT_UNIFIED
;
ops
->
cgroup_layout
=
CGROUP_LAYOUT_UNIFIED
;
ops
->
unified
=
new
;
ops
->
unified
=
add_hierarchy
(
&
ops
->
hierarchies
,
delegatable
,
mountpoint
,
base_cgroup
,
CGROUP2_SUPER_MAGIC
);
return
CGROUP2_SUPER_MAGIC
;
return
CGROUP2_SUPER_MAGIC
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment