1 // SPDX-License-Identifier: GPL-2.0-only 1 2 /* 3 * Copyright 2012 (C), Thomas Petazzoni <thoma 4 * 5 * arch/arm/mach-orion5x/board-dt.c 6 * 7 * Flattened Device Tree board initialization 8 */ 9 10 #include <linux/kernel.h> 11 #include <linux/init.h> 12 #include <linux/of.h> 13 #include <linux/of_platform.h> 14 #include <linux/cpu.h> 15 #include <linux/mbus.h> 16 #include <linux/clocksource.h> 17 #include <asm/system_misc.h> 18 #include <asm/mach/arch.h> 19 #include <asm/mach/map.h> 20 #include <plat/irq.h> 21 #include <plat/time.h> 22 #include "orion5x.h" 23 #include "bridge-regs.h" 24 #include "common.h" 25 26 static struct of_dev_auxdata orion5x_auxdata_l 27 OF_DEV_AUXDATA("marvell,orion-spi", 0x 28 OF_DEV_AUXDATA("marvell,mv64xxx-i2c", 29 NULL), 30 OF_DEV_AUXDATA("marvell,orion-wdt", 0x 31 OF_DEV_AUXDATA("marvell,orion-sata", 0 32 OF_DEV_AUXDATA("marvell,orion-crypto", 33 {}, 34 }; 35 36 static void __init orion5x_dt_init(void) 37 { 38 char *dev_name; 39 u32 dev, rev; 40 41 orion5x_id(&dev, &rev, &dev_name); 42 printk(KERN_INFO "Orion ID: %s. TCLK=% 43 44 BUG_ON(mvebu_mbus_dt_init(false)); 45 46 /* 47 * Setup Orion address map 48 */ 49 orion5x_setup_wins(); 50 51 /* 52 * Don't issue "Wait for Interrupt" in 53 * running on D0 5281 silicon. 54 */ 55 if (dev == MV88F5281_DEV_ID && rev == 56 printk(KERN_INFO "Orion: Apply 57 cpu_idle_poll_ctrl(true); 58 } 59 60 if (of_machine_is_compatible("maxtor,s 61 mss2_init(); 62 63 if (of_machine_is_compatible("lacie,d2 64 d2net_init(); 65 66 of_platform_default_populate(NULL, ori 67 } 68 69 static const char *orion5x_dt_compat[] = { 70 "marvell,orion5x", 71 NULL, 72 }; 73 74 DT_MACHINE_START(ORION5X_DT, "Marvell Orion5x 75 /* Maintainer: Thomas Petazzoni <thoma 76 .map_io = orion5x_map_io, 77 .init_machine = orion5x_dt_init, 78 .restart = orion5x_restart, 79 .dt_compat = orion5x_dt_compat, 80 MACHINE_END 81
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.