summaryrefslogtreecommitdiff
path: root/arch/microblaze
diff options
context:
space:
mode:
authorJeremy Kerr <jeremy.kerr@canonical.com>2010-01-30 01:31:21 -0700
committerGrant Likely <grant.likely@secretlab.ca>2010-02-09 08:34:10 -0700
commit1406bc2f57787797d1f6a3675c019a7093769275 (patch)
tree2b3bee50a75fa1502ef00eccf7bcecda19acd56a /arch/microblaze
parent50ab2fe147e22c8786552cda1791a61ae81b84d2 (diff)
of/flattree: use callback to setup initrd from /chosen
At present, the fdt code sets the kernel-wide initrd_start and initrd_end variables when parsing /chosen. On ARM, we only set these once the bootmem has been reserved. This change adds an arch hook to setup the initrd from the device tree: void early_init_dt_setup_initrd_arch(unsigned long start, unsigned long end); The arch-specific code can then setup the initrd however it likes. Compiled on powerpc, with CONFIG_BLK_DEV_INITRD=y and =n. Signed-off-by: Jeremy Kerr <jeremy.kerr@canonical.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'arch/microblaze')
-rw-r--r--arch/microblaze/kernel/prom.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/microblaze/kernel/prom.c b/arch/microblaze/kernel/prom.c
index 459c32e4a5fe..050b7993c51c 100644
--- a/arch/microblaze/kernel/prom.c
+++ b/arch/microblaze/kernel/prom.c
@@ -118,6 +118,16 @@ void __init early_init_devtree(void *params)
pr_debug(" <- early_init_devtree()\n");
}
+#ifdef CONFIG_BLK_DEV_INITRD
+void __init early_init_dt_setup_initrd_arch(unsigned long start,
+ unsigned long end)
+{
+ initrd_start = (unsigned long)__va(start);
+ initrd_end = (unsigned long)__va(end);
+ initrd_below_start_ok = 1;
+}
+#endif
+
/*******
*
* New implementation of the OF "find" APIs, return a refcounted