
hulk inclusion category: bugfix bugzilla: https://gitee.com/src-openeuler/kernel/issues/IBP72X CVE: CVE-2022-49647 ---------------------------------------------------------------------- Fix kabi caused by previous patch. Fixes: 7974fce333d8 ("cgroup: Use separate src/dst nodes when preloading css_sets for migration") Signed-off-by: Chen Ridong <chenridong@huawei.com> --- include/linux/cgroup-defs.h | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/include/linux/cgroup-defs.h b/include/linux/cgroup-defs.h index 77c5cbf7662f..e27891a1fae7 100644 --- a/include/linux/cgroup-defs.h +++ b/include/linux/cgroup-defs.h @@ -223,6 +223,11 @@ struct css_set { /* all threaded csets whose ->dom_cset points to this cset */ struct list_head threaded_csets; + + /* This is only used for cgroup v2 threaded, and is empty for + * cgroup v1. Use it as mg_dst_preload_node to keep KABI, this is + * fine for cgroup v1. For 4.18 4.19, only cgroup v1 is supported. + */ struct list_head threaded_csets_node; /* @@ -240,9 +245,12 @@ struct css_set { /* * List of csets participating in the on-going migration either as * source or destination. Protected by cgroup_mutex. + * mg_preload_node -> used as mg_src_preload_node to keep KABI + */ + struct list_head mg_preload_node; + /* struct list_head mg_dst_preload_node; + * is disguised by threaded_csets_node */ - struct list_head mg_src_preload_node; - struct list_head mg_dst_preload_node; struct list_head mg_node; /* @@ -263,6 +271,10 @@ struct css_set { struct rcu_head rcu_head; }; +/* To keep KABI, define the name to disguised */ +#define mg_src_preload_node mg_preload_node +#define mg_dst_preload_node threaded_csets_node + struct cgroup_base_stat { struct task_cputime cputime; }; -- 2.34.1