Commit 621c2cd8 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Jonas Bonn

openrisc: Refactor or32_early_setup()

  - Change fdt pointer (passed from head.S) from unsigned int to void *,
    which allows to kill a cast, and makes it compatible with __dtb_start.
  - Use pr_info(),
  - Extract common part.
Signed-off-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Cc: linux@lists.openrisc.net
Signed-off-by: default avatarJonas Bonn <jonas@southpole.se>
parent 0db041be
...@@ -210,15 +210,15 @@ void __init setup_cpuinfo(void) ...@@ -210,15 +210,15 @@ void __init setup_cpuinfo(void)
* Falls back on built-in device tree in case null pointer is passed. * Falls back on built-in device tree in case null pointer is passed.
*/ */
void __init or32_early_setup(unsigned int fdt) void __init or32_early_setup(void *fdt)
{ {
if (fdt) { if (fdt)
early_init_devtree((void*) fdt); pr_info("FDT at %p\n", fdt);
printk(KERN_INFO "FDT at 0x%08x\n", fdt); else {
} else { fdt = __dtb_start;
early_init_devtree(__dtb_start); pr_info("Compiled-in FDT at %p\n", fdt);
printk(KERN_INFO "Compiled-in FDT at %p\n", __dtb_start);
} }
early_init_devtree(fdt);
} }
static int __init openrisc_device_probe(void) static int __init openrisc_device_probe(void)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment