aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorMagnus Damm <damm@opensource.se>2013-11-06 18:21:11 -0500
committerSimon Horman <horms+renesas@verge.net.au>2013-12-04 01:11:14 -0500
commita3153e6cbaa878c52bcd547f24f89282c660e2e7 (patch)
tree807321228608418fa25b194213bc2dd334856845 /arch
parentd18e06116d5e7b277e73e3bdc6e08208aabcedc7 (diff)
ARM: shmobile: Add shared EMEV2 code for ->init_machine()
Add a SoC specific function that initializes clocks and starts DT probing in case of EMEV2. This EMEV2 SoC support code may be built for either legacy SHMOBILE or SMOBILE_MULTI. The change allows us to support existing board specific KZM9D DTB with these SoC specific DT_MACHINE_START() callbacks. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-shmobile/setup-emev2.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/arm/mach-shmobile/setup-emev2.c b/arch/arm/mach-shmobile/setup-emev2.c
index 3ad531caf4f0..2d64b95dcc43 100644
--- a/arch/arm/mach-shmobile/setup-emev2.c
+++ b/arch/arm/mach-shmobile/setup-emev2.c
@@ -16,6 +16,7 @@
16 * along with this program; if not, write to the Free Software 16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 */ 18 */
19#include <linux/clk-provider.h>
19#include <linux/kernel.h> 20#include <linux/kernel.h>
20#include <linux/init.h> 21#include <linux/init.h>
21#include <linux/interrupt.h> 22#include <linux/interrupt.h>
@@ -197,6 +198,16 @@ void __init emev2_init_delay(void)
197 198
198#ifdef CONFIG_USE_OF 199#ifdef CONFIG_USE_OF
199 200
201static void __init emev2_add_standard_devices_dt(void)
202{
203#ifdef CONFIG_COMMON_CLK
204 of_clk_init(NULL);
205#else
206 emev2_clock_init();
207#endif
208 of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
209}
210
200static const char *emev2_boards_compat_dt[] __initdata = { 211static const char *emev2_boards_compat_dt[] __initdata = {
201 "renesas,emev2", 212 "renesas,emev2",
202 NULL, 213 NULL,
@@ -206,6 +217,7 @@ DT_MACHINE_START(EMEV2_DT, "Generic Emma Mobile EV2 (Flattened Device Tree)")
206 .smp = smp_ops(emev2_smp_ops), 217 .smp = smp_ops(emev2_smp_ops),
207 .map_io = emev2_map_io, 218 .map_io = emev2_map_io,
208 .init_early = emev2_init_delay, 219 .init_early = emev2_init_delay,
220 .init_machine = emev2_add_standard_devices_dt,
209 .dt_compat = emev2_boards_compat_dt, 221 .dt_compat = emev2_boards_compat_dt,
210MACHINE_END 222MACHINE_END
211 223