memcg: fix section mismatch
Subsystems (2)
PATCH v2 1/1 memcg: fix section mismatch
At system boot when creating the top cgroup, mem_cgroup_create() calls enable_swap_cgroup() which is marked as __init, so mark mem_cgroup_create() as __ref to avoid false section mismatch warning.
---
use __ref instead of __init_refok
--- mm/memcontrol.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
mm/memcontrol.c +1 -1
@@ -2181,7 +2181,7 @@ static void __init enable_swap_cgroup(void) }#endif -static struct cgroup_subsys_state * +static struct cgroup_subsys_state *__ref mem_cgroup_create (struct cgroup_subsys *ss,struct cgroup *cont) {struct mem_cgroup *mem, *parent;
Signature · 1 line
1.5.4.rc3
Quoted 6 lines · On Wed, 14 Jan 2009 15:04:32 +0800 Li Zefan <[email protected]> wrote:
At system boot when creating the top cgroup,
mem_cgroup_create()callsenable_swap_cgroup()which is marked as__init, so markmem_cgroup_create()as__refto avoid false section mismatch warning.Reported-by Rakib Mullick <[email protected]>Signed-off-by Li Zefan <[email protected]>
Acked-by; KAMEZAWA Hiroyuki <[email protected]>
Quoted 4 lines
---
use
__refinstead of__init_refok
change log ?
Quoted 20 lines
--- mm/memcontrol.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)mm/memcontrol.c +1
-1@@ -2181,7 +2181,7 @@ static void __init enable_swap_cgroup(void) }#endif -static struct cgroup_subsys_state * +static struct cgroup_subsys_state *__ref mem_cgroup_create (struct cgroup_subsys *ss,struct cgroup *cont) {struct mem_cgroup *mem, *parent;Signature · 1 line
1.5.4.rc3
Quoted 10 lines · KAMEZAWA Hiroyuki
Quoted 6 lines · On Wed, 14 Jan 2009 15:04:32 +0800 Li Zefan <[email protected]> wrote:
At system boot when creating the top cgroup,
mem_cgroup_create()callsenable_swap_cgroup()which is marked as__init, so markmem_cgroup_create()as__refto avoid false section mismatch warning.Reported-by Rakib Mullick <[email protected]>Signed-off-by Li Zefan <[email protected]>
Quoted 8 lines
Acked-by; KAMEZAWA Hiroyuki <[email protected]>
Quoted 4 lines
---
use
__refinstead of__init_refokchange log ?
Yes. But for this simple patch, I don't think change log for v1 -> v2 is worth anything for the normal changelog. :)