]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
page_alloc: break early in check_for_regular_memory()
authorBob Liu <lliubbo@gmail.com>
Fri, 13 Jan 2012 01:19:07 +0000 (17:19 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 13 Jan 2012 04:13:07 +0000 (20:13 -0800)
commitd0048b0e59c1218d62bb4d014f34bbd7e7c0a214
treef6a69889bcb60b253ab37029616ebe6fa2bd24f9
parent3ed28fa1080c73747ce17f2025b28b062fb5aa7f
page_alloc: break early in check_for_regular_memory()

If there is a zone below ZONE_NORMAL has present_pages, we can set node
state to N_NORMAL_MEMORY, no need to loop to end.

Signed-off-by: Bob Liu <lliubbo@gmail.com>
Acked-by: Michal Hocko <mhocko@suse.cz>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/page_alloc.c