|
@@ -6467,15 +6467,18 @@ void __init free_area_init_nodes(unsigned long *max_zone_pfn)
|
|
|
sizeof(arch_zone_lowest_possible_pfn));
|
|
sizeof(arch_zone_lowest_possible_pfn));
|
|
|
memset(arch_zone_highest_possible_pfn, 0,
|
|
memset(arch_zone_highest_possible_pfn, 0,
|
|
|
sizeof(arch_zone_highest_possible_pfn));
|
|
sizeof(arch_zone_highest_possible_pfn));
|
|
|
- arch_zone_lowest_possible_pfn[0] = find_min_pfn_with_active_regions();
|
|
|
|
|
- arch_zone_highest_possible_pfn[0] = max_zone_pfn[0];
|
|
|
|
|
- for (i = 1; i < MAX_NR_ZONES; i++) {
|
|
|
|
|
|
|
+
|
|
|
|
|
+ start_pfn = find_min_pfn_with_active_regions();
|
|
|
|
|
+
|
|
|
|
|
+ for (i = 0; i < MAX_NR_ZONES; i++) {
|
|
|
if (i == ZONE_MOVABLE)
|
|
if (i == ZONE_MOVABLE)
|
|
|
continue;
|
|
continue;
|
|
|
- arch_zone_lowest_possible_pfn[i] =
|
|
|
|
|
- arch_zone_highest_possible_pfn[i-1];
|
|
|
|
|
- arch_zone_highest_possible_pfn[i] =
|
|
|
|
|
- max(max_zone_pfn[i], arch_zone_lowest_possible_pfn[i]);
|
|
|
|
|
|
|
+
|
|
|
|
|
+ end_pfn = max(max_zone_pfn[i], start_pfn);
|
|
|
|
|
+ arch_zone_lowest_possible_pfn[i] = start_pfn;
|
|
|
|
|
+ arch_zone_highest_possible_pfn[i] = end_pfn;
|
|
|
|
|
+
|
|
|
|
|
+ start_pfn = end_pfn;
|
|
|
}
|
|
}
|
|
|
arch_zone_lowest_possible_pfn[ZONE_MOVABLE] = 0;
|
|
arch_zone_lowest_possible_pfn[ZONE_MOVABLE] = 0;
|
|
|
arch_zone_highest_possible_pfn[ZONE_MOVABLE] = 0;
|
|
arch_zone_highest_possible_pfn[ZONE_MOVABLE] = 0;
|