The patch titled Subject: page_alloc: bootmem limit with movablecore_map has been removed from the -mm tree. Its filename was page_alloc-bootmem-limit-with-movablecore_map.patch This patch was dropped because it was merged into mainline or a subsystem tree ------------------------------------------------------ From: Tang Chen <tangchen@xxxxxxxxxxxxxx> Subject: page_alloc: bootmem limit with movablecore_map Ensure the bootmem will not allocate memory from areas that may be ZONE_MOVABLE. The map info is from movablecore_map boot option. Signed-off-by: Tang Chen <tangchen@xxxxxxxxxxxxxx> Reviewed-by: Wen Congyang <wency@xxxxxxxxxxxxxx> Reviewed-by: Lai Jiangshan <laijs@xxxxxxxxxxxxxx> Tested-by: Lin Feng <linfeng@xxxxxxxxxxxxxx> Cc: Wu Jianguo <wujianguo@xxxxxxxxxx> Cc: Mel Gorman <mel@xxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxx> Cc: "H. Peter Anvin" <hpa@xxxxxxxxx> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- include/linux/memblock.h | 1 + mm/memblock.c | 18 +++++++++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff -puN include/linux/memblock.h~page_alloc-bootmem-limit-with-movablecore_map include/linux/memblock.h --- a/include/linux/memblock.h~page_alloc-bootmem-limit-with-movablecore_map +++ a/include/linux/memblock.h @@ -42,6 +42,7 @@ struct memblock { extern struct memblock memblock; extern int memblock_debug; +extern struct movablemem_map movablemem_map; #define memblock_dbg(fmt, ...) \ if (memblock_debug) printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) diff -puN mm/memblock.c~page_alloc-bootmem-limit-with-movablecore_map mm/memblock.c --- a/mm/memblock.c~page_alloc-bootmem-limit-with-movablecore_map +++ a/mm/memblock.c @@ -101,6 +101,7 @@ phys_addr_t __init_memblock memblock_fin { phys_addr_t this_start, this_end, cand; u64 i; + int curr = movablemem_map.nr_map - 1; /* pump up @end */ if (end == MEMBLOCK_ALLOC_ACCESSIBLE) @@ -114,13 +115,28 @@ phys_addr_t __init_memblock memblock_fin this_start = clamp(this_start, start, end); this_end = clamp(this_end, start, end); - if (this_end < size) +restart: + if (this_end <= this_start || this_end < size) continue; + for (; curr >= 0; curr--) { + if ((movablemem_map.map[curr].start_pfn << PAGE_SHIFT) + < this_end) + break; + } + cand = round_down(this_end - size, align); + if (curr >= 0 && + cand < movablemem_map.map[curr].end_pfn << PAGE_SHIFT) { + this_end = movablemem_map.map[curr].start_pfn + << PAGE_SHIFT; + goto restart; + } + if (cand >= this_start) return cand; } + return 0; } _ Patches currently in -mm which might be from tangchen@xxxxxxxxxxxxxx are origin.patch linux-next.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html