blob: dd04d7d4a02e74367ba2f148c125aa1a9f49f90d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
/*
* ext_bootmem.c
*/
#include <linux/bootmem.h>
#include <linux/ext_bootmem.h>
#include <linux/sizes.h>
#include <linux/mmzone.h>
#include <linux/memblock.h>
#include <asm/memory.h>
#define _DEBUG
void __init reserve_ext_bootmem(void)
{
if (memblock_reserve(PRE_RESERVED_PA_START, PRE_RESERVED_PA_SIZE)) {
printk("memblock reserve is failed!(pa: 0x%08X, size: 0x%08X)\n",
PRE_RESERVED_PA_START, PRE_RESERVED_PA_SIZE);
return;
} else {
#ifdef _DEBUG
printk("Pre-reserved Memory : SUCCESS\n");
printk("- Physical memory = 0x%08X ~ 0x%08X\n",
PRE_RESERVED_PA_START,
PRE_RESERVED_PA_START + PRE_RESERVED_PA_SIZE);
printk("- Pre-reserved size = %d KB\n", PRE_RESERVED_PA_SIZE >> 10);
#endif
}
}
|