Skip to content

Commit

Permalink
openrisc: Refactor or32_early_setup()
Browse files Browse the repository at this point in the history
  - 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: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: linux@lists.openrisc.net
Signed-off-by: Jonas Bonn <jonas@southpole.se>
  • Loading branch information
geertu authored and Jonas Bonn committed Nov 15, 2013
1 parent 0db041b commit 621c2cd
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions arch/openrisc/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -210,15 +210,15 @@ void __init setup_cpuinfo(void)
* 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) {
early_init_devtree((void*) fdt);
printk(KERN_INFO "FDT at 0x%08x\n", fdt);
} else {
early_init_devtree(__dtb_start);
printk(KERN_INFO "Compiled-in FDT at %p\n", __dtb_start);
if (fdt)
pr_info("FDT at %p\n", fdt);
else {
fdt = __dtb_start;
pr_info("Compiled-in FDT at %p\n", fdt);
}
early_init_devtree(fdt);
}

static int __init openrisc_device_probe(void)
Expand Down

0 comments on commit 621c2cd

Please sign in to comment.