14 #include <linux/module.h>
17 #include <asm/setup.h>
38 static void __init mem_prof_init(
void)
40 unsigned long start_pfn, holes, free_pfn;
41 const unsigned long zone_alignment = 1
UL << (
MAX_ORDER - 1);
54 start_pfn = free_pfn =
PFN_UP(CONFIG_IRAM_START);
56 if (start_pfn & (zone_alignment - 1)) {
58 while (start_pfn >= ul)
61 start_pfn = ul - zone_alignment;
62 holes = free_pfn - start_pfn;
73 unsigned long bootmap_size;
74 unsigned long min_pfn;
106 #ifdef CONFIG_BLK_DEV_INITRD
113 printk(
"initrd:start[%08lx],size[%08lx]\n",
116 printk(
"initrd extends beyond end of memory "
117 "(0x%08lx > 0x%08llx)\ndisabling initrd\n",
129 #define START_PFN(nid) (NODE_DATA(nid)->bdata->node_min_pfn)
130 #define MAX_LOW_PFN(nid) (NODE_DATA(nid)->bdata->node_low_pfn)
134 unsigned long zones_size[MAX_NR_ZONES], zholes_size[MAX_NR_ZONES];
135 unsigned long low, start_pfn;
136 unsigned long holes = 0;
142 for (i = 0 ; i < MAX_NR_ZONES ; i++) {
148 zones_size[ZONE_DMA] = low - start_pfn;
149 zholes_size[ZONE_DMA] = mp->
holes;
150 holes += zholes_size[ZONE_DMA];