xref: /linux/arch/arm/mach-imx/mach-vf610.c (revision 5be913c6824e1957e03ae432b60717c21f2c53d1)
1*5be913c6SJingchang Lu /*
2*5be913c6SJingchang Lu  * Copyright 2012-2013 Freescale Semiconductor, Inc.
3*5be913c6SJingchang Lu  *
4*5be913c6SJingchang Lu  * This program is free software; you can redistribute it and/or modify
5*5be913c6SJingchang Lu  * it under the terms of the GNU General Public License as published by
6*5be913c6SJingchang Lu  * the Free Software Foundation; either version 2 of the License, or
7*5be913c6SJingchang Lu  * (at your option) any later version.
8*5be913c6SJingchang Lu  */
9*5be913c6SJingchang Lu 
10*5be913c6SJingchang Lu #include <linux/of_platform.h>
11*5be913c6SJingchang Lu #include <linux/clocksource.h>
12*5be913c6SJingchang Lu #include <linux/irqchip.h>
13*5be913c6SJingchang Lu #include <linux/clk-provider.h>
14*5be913c6SJingchang Lu #include <asm/mach/arch.h>
15*5be913c6SJingchang Lu #include <asm/hardware/cache-l2x0.h>
16*5be913c6SJingchang Lu 
17*5be913c6SJingchang Lu #include "common.h"
18*5be913c6SJingchang Lu 
19*5be913c6SJingchang Lu static void __init vf610_init_machine(void)
20*5be913c6SJingchang Lu {
21*5be913c6SJingchang Lu 	mxc_arch_reset_init_dt();
22*5be913c6SJingchang Lu 	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
23*5be913c6SJingchang Lu }
24*5be913c6SJingchang Lu 
25*5be913c6SJingchang Lu static void __init vf610_init_irq(void)
26*5be913c6SJingchang Lu {
27*5be913c6SJingchang Lu 	l2x0_of_init(0, ~0UL);
28*5be913c6SJingchang Lu 	irqchip_init();
29*5be913c6SJingchang Lu }
30*5be913c6SJingchang Lu 
31*5be913c6SJingchang Lu static void __init vf610_init_time(void)
32*5be913c6SJingchang Lu {
33*5be913c6SJingchang Lu 	of_clk_init(NULL);
34*5be913c6SJingchang Lu 	clocksource_of_init();
35*5be913c6SJingchang Lu }
36*5be913c6SJingchang Lu 
37*5be913c6SJingchang Lu static const char *vf610_dt_compat[] __initdata = {
38*5be913c6SJingchang Lu 	"fsl,vf610",
39*5be913c6SJingchang Lu 	NULL,
40*5be913c6SJingchang Lu };
41*5be913c6SJingchang Lu 
42*5be913c6SJingchang Lu DT_MACHINE_START(VYBRID_VF610, "Freescale Vybrid VF610 (Device Tree)")
43*5be913c6SJingchang Lu 	.init_irq	= vf610_init_irq,
44*5be913c6SJingchang Lu 	.init_time	= vf610_init_time,
45*5be913c6SJingchang Lu 	.init_machine   = vf610_init_machine,
46*5be913c6SJingchang Lu 	.dt_compat	= vf610_dt_compat,
47*5be913c6SJingchang Lu 	.restart	= mxc_restart,
48*5be913c6SJingchang Lu MACHINE_END
49