projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ec2adcd
)
powerpc/prom: move the device tree if not in declared memory.
author
Christophe Leroy
<
[email protected]
>
Mon, 17 Dec 2018 14:18:27 +0000
(14:18 +0000)
committer
Michael Ellerman
<
[email protected]
>
Thu, 20 Dec 2018 11:21:20 +0000
(22:21 +1100)
If the device tree doesn't reside in the memory which is declared
inside it, it has to be moved as well as this memory will not be
mapped by the kernel.
Signed-off-by: Christophe Leroy <
[email protected]
>
Signed-off-by: Michael Ellerman <
[email protected]
>
arch/powerpc/kernel/prom.c
patch
|
blob
|
history
diff --git
a/arch/powerpc/kernel/prom.c
b/arch/powerpc/kernel/prom.c
index 87a68e2dc531023b6009d63006bc424b955fa8ac..4181ec715f8889c4bf041b74da247632c7a2f651 100644
(file)
--- a/
arch/powerpc/kernel/prom.c
+++ b/
arch/powerpc/kernel/prom.c
@@
-124,8
+124,8
@@
static void __init move_device_tree(void)
size = fdt_totalsize(initial_boot_params);
if ((memory_limit && (start + size) > PHYSICAL_START + memory_limit) ||
-
overlaps_crashkernel(start, size
) ||
-
overlaps_initrd(start, size)) {
+
!memblock_is_memory(start + size - 1
) ||
+
overlaps_crashkernel(start, size) ||
overlaps_initrd(start, size)) {
p = __va(memblock_phys_alloc(size, PAGE_SIZE));
memcpy(p, initial_boot_params, size);
initial_boot_params = p;