aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/powerpc/kernel/prom.c5
-rw-r--r--arch/powerpc/kernel/prom_init.c9
2 files changed, 9 insertions, 5 deletions
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index 8d0415b080bb..969f4abcc0be 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -1267,6 +1267,11 @@ static void __init early_reserve_mem(void)
1267 1267
1268 reserve_map = (u64 *)(((unsigned long)initial_boot_params) + 1268 reserve_map = (u64 *)(((unsigned long)initial_boot_params) +
1269 initial_boot_params->off_mem_rsvmap); 1269 initial_boot_params->off_mem_rsvmap);
1270
1271 /* before we do anything, lets reserve the dt blob */
1272 lmb_reserve(__pa((unsigned long)initial_boot_params),
1273 initial_boot_params->totalsize);
1274
1270#ifdef CONFIG_PPC32 1275#ifdef CONFIG_PPC32
1271 /* 1276 /*
1272 * Handle the case where we might be booting from an old kexec 1277 * Handle the case where we might be booting from an old kexec
diff --git a/arch/powerpc/kernel/prom_init.c b/arch/powerpc/kernel/prom_init.c
index 2442361772e2..98e201c38d27 100644
--- a/arch/powerpc/kernel/prom_init.c
+++ b/arch/powerpc/kernel/prom_init.c
@@ -1950,11 +1950,7 @@ static void __init flatten_device_tree(void)
1950 /* Version 16 is not backward compatible */ 1950 /* Version 16 is not backward compatible */
1951 hdr->last_comp_version = 0x10; 1951 hdr->last_comp_version = 0x10;
1952 1952
1953 /* Reserve the whole thing and copy the reserve map in, we 1953 /* Copy the reserve map in */
1954 * also bump mem_reserve_cnt to cause further reservations to
1955 * fail since it's too late.
1956 */
1957 reserve_mem(RELOC(dt_header_start), hdr->totalsize);
1958 memcpy(rsvmap, RELOC(mem_reserve_map), sizeof(mem_reserve_map)); 1954 memcpy(rsvmap, RELOC(mem_reserve_map), sizeof(mem_reserve_map));
1959 1955
1960#ifdef DEBUG_PROM 1956#ifdef DEBUG_PROM
@@ -1967,6 +1963,9 @@ static void __init flatten_device_tree(void)
1967 RELOC(mem_reserve_map)[i].size); 1963 RELOC(mem_reserve_map)[i].size);
1968 } 1964 }
1969#endif 1965#endif
1966 /* Bump mem_reserve_cnt to cause further reservations to fail
1967 * since it's too late.
1968 */
1970 RELOC(mem_reserve_cnt) = MEM_RESERVE_MAP_SIZE; 1969 RELOC(mem_reserve_cnt) = MEM_RESERVE_MAP_SIZE;
1971 1970
1972 prom_printf("Device tree strings 0x%x -> 0x%x\n", 1971 prom_printf("Device tree strings 0x%x -> 0x%x\n",