mm/memblock: use existing interface to set nid
authorWanpeng Li <liwanp@linux.vnet.ibm.com>
Mon, 8 Oct 2012 23:32:21 +0000 (16:32 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 9 Oct 2012 07:22:47 +0000 (16:22 +0900)
Use the existing interface function to set the NUMA node ID (NID) for the
regions, either memory or reserved region.

Signed-off-by: Wanpeng Li <liwanp@linux.vnet.ibm.com>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Minchan Kim <minchan@kernel.org>
Cc: Gavin Shan <shangw@linux.vnet.ibm.com>
Cc: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/memblock.c

index 82aa349d2f7a040b489bee441bf848b61119f788..d809f17ef75be70004def826f6ea7baed9267028 100644 (file)
@@ -756,7 +756,7 @@ int __init_memblock memblock_set_node(phys_addr_t base, phys_addr_t size,
                return ret;
 
        for (i = start_rgn; i < end_rgn; i++)
-               type->regions[i].nid = nid;
+               memblock_set_region_node(&type->regions[i], nid);
 
        memblock_merge_regions(type);
        return 0;