summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorHeiko Schocher <hs@denx.de>2008-09-11 08:11:23 +0200
committerWolfgang Denk <wd@denx.de>2008-09-13 02:03:38 +0200
commit56844a22b76c719e600047e23b80465a44d76abd (patch)
tree1a2776838726eee8f4f1ac1f389a0f25a30f162e /include
parentfc9c1727b5b3483ce49c3cb668e8332fb001b8a7 (diff)
powerpc: Fix bootm to boot up again with a Ramdisk
Commit 2a1a2cb6 didnt remove the dummy mem reservation in fdt_chosen, and this stopped Linux from booting with a Ramdisk. This patch fixes this, by deleting the useless dummy mem reservation. When booting with a Ramdisk, a fix offset FDT_RAMDISK_OVERHEAD is now added to of_size, so we dont need anymore a dummy mem reservation. I measured the value of FDT_RAMDISK_OVERHEAD on a MPC8270 based system (=0x44 bytes) and rounded it up to 0x80). Signed-off-by: Heiko Schocher <hs@denx.de> Acked-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'include')
-rw-r--r--include/fdt.h2
-rw-r--r--include/fdt_support.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/include/fdt.h b/include/fdt.h
index 48ccfd91000..c51212e05b4 100644
--- a/include/fdt.h
+++ b/include/fdt.h
@@ -57,4 +57,6 @@ struct fdt_property {
#define FDT_V16_SIZE FDT_V3_SIZE
#define FDT_V17_SIZE (FDT_V16_SIZE + sizeof(uint32_t))
+/* adding a ramdisk needs 0x44 bytes in version 2008.10 */
+#define FDT_RAMDISK_OVERHEAD 0x80
#endif /* _FDT_H */
diff --git a/include/fdt_support.h b/include/fdt_support.h
index 424c3c6b7e0..ceaadc2bef7 100644
--- a/include/fdt_support.h
+++ b/include/fdt_support.h
@@ -28,7 +28,7 @@
#include <fdt.h>
-int fdt_chosen(void *fdt, ulong initrd_start, ulong initrd_end, int force);
+int fdt_chosen(void *fdt, int force);
int fdt_initrd(void *fdt, ulong initrd_start, ulong initrd_end, int force);
void do_fixup_by_path(void *fdt, const char *path, const char *prop,
const void *val, int len, int create);