diff options
Diffstat (limited to 'mm/memory_hotplug.c')
-rw-r--r-- | mm/memory_hotplug.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c index e882cb6da994..d4b5f29906b9 100644 --- a/mm/memory_hotplug.c +++ b/mm/memory_hotplug.c | |||
@@ -328,6 +328,7 @@ int __ref __add_pages(int nid, unsigned long phys_start_pfn, | |||
328 | if (err && (err != -EEXIST)) | 328 | if (err && (err != -EEXIST)) |
329 | break; | 329 | break; |
330 | err = 0; | 330 | err = 0; |
331 | cond_resched(); | ||
331 | } | 332 | } |
332 | vmemmap_populate_print_last(); | 333 | vmemmap_populate_print_last(); |
333 | out: | 334 | out: |
@@ -337,7 +338,7 @@ EXPORT_SYMBOL_GPL(__add_pages); | |||
337 | 338 | ||
338 | #ifdef CONFIG_MEMORY_HOTREMOVE | 339 | #ifdef CONFIG_MEMORY_HOTREMOVE |
339 | /* find the smallest valid pfn in the range [start_pfn, end_pfn) */ | 340 | /* find the smallest valid pfn in the range [start_pfn, end_pfn) */ |
340 | static int find_smallest_section_pfn(int nid, struct zone *zone, | 341 | static unsigned long find_smallest_section_pfn(int nid, struct zone *zone, |
341 | unsigned long start_pfn, | 342 | unsigned long start_pfn, |
342 | unsigned long end_pfn) | 343 | unsigned long end_pfn) |
343 | { | 344 | { |
@@ -362,7 +363,7 @@ static int find_smallest_section_pfn(int nid, struct zone *zone, | |||
362 | } | 363 | } |
363 | 364 | ||
364 | /* find the biggest valid pfn in the range [start_pfn, end_pfn). */ | 365 | /* find the biggest valid pfn in the range [start_pfn, end_pfn). */ |
365 | static int find_biggest_section_pfn(int nid, struct zone *zone, | 366 | static unsigned long find_biggest_section_pfn(int nid, struct zone *zone, |
366 | unsigned long start_pfn, | 367 | unsigned long start_pfn, |
367 | unsigned long end_pfn) | 368 | unsigned long end_pfn) |
368 | { | 369 | { |
@@ -550,7 +551,7 @@ static int __remove_section(struct zone *zone, struct mem_section *ms, | |||
550 | return ret; | 551 | return ret; |
551 | 552 | ||
552 | scn_nr = __section_nr(ms); | 553 | scn_nr = __section_nr(ms); |
553 | start_pfn = section_nr_to_pfn(scn_nr); | 554 | start_pfn = section_nr_to_pfn((unsigned long)scn_nr); |
554 | __remove_zone(zone, start_pfn); | 555 | __remove_zone(zone, start_pfn); |
555 | 556 | ||
556 | sparse_remove_one_section(zone, ms, map_offset); | 557 | sparse_remove_one_section(zone, ms, map_offset); |