diff options
Diffstat (limited to 'mm/memcontrol.c')
-rw-r--r-- | mm/memcontrol.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 6bded84c20c8..631002d085d1 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c | |||
@@ -534,7 +534,6 @@ unsigned long mem_cgroup_isolate_pages(unsigned long nr_to_scan, | |||
534 | if (scan >= nr_to_scan) | 534 | if (scan >= nr_to_scan) |
535 | break; | 535 | break; |
536 | page = pc->page; | 536 | page = pc->page; |
537 | VM_BUG_ON(!pc); | ||
538 | 537 | ||
539 | if (unlikely(!PageLRU(page))) | 538 | if (unlikely(!PageLRU(page))) |
540 | continue; | 539 | continue; |
@@ -1101,7 +1100,7 @@ mem_cgroup_create(struct cgroup_subsys *ss, struct cgroup *cont) | |||
1101 | mem = kzalloc(sizeof(struct mem_cgroup), GFP_KERNEL); | 1100 | mem = kzalloc(sizeof(struct mem_cgroup), GFP_KERNEL); |
1102 | 1101 | ||
1103 | if (mem == NULL) | 1102 | if (mem == NULL) |
1104 | return NULL; | 1103 | return ERR_PTR(-ENOMEM); |
1105 | 1104 | ||
1106 | res_counter_init(&mem->res); | 1105 | res_counter_init(&mem->res); |
1107 | 1106 | ||
@@ -1117,7 +1116,7 @@ free_out: | |||
1117 | free_mem_cgroup_per_zone_info(mem, node); | 1116 | free_mem_cgroup_per_zone_info(mem, node); |
1118 | if (cont->parent != NULL) | 1117 | if (cont->parent != NULL) |
1119 | kfree(mem); | 1118 | kfree(mem); |
1120 | return NULL; | 1119 | return ERR_PTR(-ENOMEM); |
1121 | } | 1120 | } |
1122 | 1121 | ||
1123 | static void mem_cgroup_pre_destroy(struct cgroup_subsys *ss, | 1122 | static void mem_cgroup_pre_destroy(struct cgroup_subsys *ss, |