From: Li Zefan Date: Sat, 23 Feb 2008 23:24:13 +0000 (-0800) Subject: memcgroup: remove a useless VM_BUG_ON() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=7fde4c3eb7ee68828d76a2148ed6d70b6a794add;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git memcgroup: remove a useless VM_BUG_ON() Remove this VM_BUG_ON(), as Balbir stated: We used to have a for loop with !list_empty() as a termination condition and VM_BUG_ON(!pc) is a spill over. With the new loop, VM_BUG_ON(!pc) does not make sense. Signed-off-by: Li Zefan Acked-by: Balbir Singh Acked-by: KAMEZAWA Hiroyuki Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 6bded84c20c8..bb4d7acfbca3 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c @@ -534,7 +534,6 @@ unsigned long mem_cgroup_isolate_pages(unsigned long nr_to_scan, if (scan >= nr_to_scan) break; page = pc->page; - VM_BUG_ON(!pc); if (unlikely(!PageLRU(page))) continue;