mm: page_alloc: introduce alloc_contig_range()
authorMichal Nazarewicz <mina86@mina86.com>
Thu, 29 Dec 2011 12:09:50 +0000 (13:09 +0100)
committerMarek Szyprowski <m.szyprowski@samsung.com>
Mon, 21 May 2012 13:09:31 +0000 (15:09 +0200)
commit041d3a8cdc18dc375a128d90bbb753949a81b1fb
tree26f5e1b30f638ea148e7deb13c44d0d0f1d39935
parentff9543fd32060917beb080b1eb2d1d41ec7f39e0
mm: page_alloc: introduce alloc_contig_range()

This commit adds the alloc_contig_range() function which tries
to allocate given range of pages.  It tries to migrate all
already allocated pages that fall in the range thus freeing them.
Once all pages in the range are freed they are removed from the
buddy system thus allocated for the caller to use.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Mel Gorman <mel@csn.ul.ie>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Rob Clark <rob.clark@linaro.org>
Tested-by: Ohad Ben-Cohen <ohad@wizery.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Tested-by: Robert Nelson <robertcnelson@gmail.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
include/linux/gfp.h
mm/page_alloc.c