1d2912cb1SThomas Gleixner // SPDX-License-Identifier: GPL-2.0-only
21dbae815STony Lindgren /*
31dbae815STony Lindgren  * Copyright (C) 2005 Nokia Corporation
41dbae815STony Lindgren  * Author: Paul Mundt <paul.mundt@nokia.com>
51dbae815STony Lindgren  *
683bf6db0SAlexander A. Klimov  * Copyright (C) 2011 Texas Instruments Incorporated - https://www.ti.com/
71dbae815STony Lindgren  *
88d61649dSBenoit Cousson  * Modified from the original mach-omap/omap2/board-generic.c did by Paul
98d61649dSBenoit Cousson  * to support the OMAP2+ device tree boards with an unique board file.
101dbae815STony Lindgren  */
118d61649dSBenoit Cousson #include <linux/io.h>
128d61649dSBenoit Cousson #include <linux/irqdomain.h>
13e69b4e1aSTony Lindgren #include <linux/clocksource.h>
14861bc1d2SArnd Bergmann #include <linux/clockchips.h>
15*1047e214SRob Herring #include <linux/mod_devicetable.h>
161dbae815STony Lindgren 
178c51b034SIvaylo Dimitrov #include <asm/setup.h>
181dbae815STony Lindgren #include <asm/mach/arch.h>
195f35dc47SIvaylo Dimitrov #include <asm/system_info.h>
201dbae815STony Lindgren 
214e65331cSTony Lindgren #include "common.h"
221dbae815STony Lindgren 
2331957609SUwe Kleine-König static const struct of_device_id omap_dt_match_table[] __initconst = {
248d61649dSBenoit Cousson 	{ .compatible = "simple-bus", },
258d61649dSBenoit Cousson 	{ .compatible = "ti,omap-infra", },
268d61649dSBenoit Cousson 	{ }
27b3c6df3aSPaul Walmsley };
28b3c6df3aSPaul Walmsley 
omap_generic_init(void)29293ea3d0SArnd Bergmann static void __init __maybe_unused omap_generic_init(void)
301dbae815STony Lindgren {
318651bd8cSTony Lindgren 	pdata_quirks_init(omap_dt_match_table);
3207e72f9aSLaurent Pinchart 	omap_soc_device_init();
331dbae815STony Lindgren }
341dbae815STony Lindgren 
35e69b4e1aSTony Lindgren /* Clocks are needed early, see drivers/clocksource for the rest */
omap_init_time_of(void)36a3efe3f6STony Lindgren static void __init __maybe_unused omap_init_time_of(void)
37e69b4e1aSTony Lindgren {
38e69b4e1aSTony Lindgren 	omap_clk_init();
39e69b4e1aSTony Lindgren 	timer_probe();
40e69b4e1aSTony Lindgren }
41e69b4e1aSTony Lindgren 
42d86ad463STony Lindgren /* Used by am437x for ARM timer in non-SMP configurations */
43d86ad463STony Lindgren #if !defined(CONFIG_SMP) && defined(CONFIG_GENERIC_CLOCKEVENTS_BROADCAST)
tick_broadcast(const struct cpumask * mask)44d86ad463STony Lindgren void tick_broadcast(const struct cpumask *mask)
45d86ad463STony Lindgren {
46d86ad463STony Lindgren }
47d86ad463STony Lindgren #endif
48d86ad463STony Lindgren 
490e02a8c1SBenoit Cousson #ifdef CONFIG_SOC_OMAP2420
5058cda01eSUwe Kleine-König static const char *const omap242x_boards_compat[] __initconst = {
518d61649dSBenoit Cousson 	"ti,omap2420",
528d61649dSBenoit Cousson 	NULL,
538d61649dSBenoit Cousson };
541dbae815STony Lindgren 
558d61649dSBenoit Cousson DT_MACHINE_START(OMAP242X_DT, "Generic OMAP2420 (Flattened Device Tree)")
5671ee7dadSRussell King 	.reserve	= omap_reserve,
578d61649dSBenoit Cousson 	.map_io		= omap242x_map_io,
588d61649dSBenoit Cousson 	.init_early	= omap2420_init_early,
591dbae815STony Lindgren 	.init_machine	= omap_generic_init,
6064dbc3d5STony Lindgren 	.init_time	= omap_init_time_of,
618d61649dSBenoit Cousson 	.dt_compat	= omap242x_boards_compat,
62187e3e06SPaul Walmsley 	.restart	= omap2xxx_restart,
631dbae815STony Lindgren MACHINE_END
648d61649dSBenoit Cousson #endif
658d61649dSBenoit Cousson 
660e02a8c1SBenoit Cousson #ifdef CONFIG_SOC_OMAP2430
6758cda01eSUwe Kleine-König static const char *const omap243x_boards_compat[] __initconst = {
688d61649dSBenoit Cousson 	"ti,omap2430",
698d61649dSBenoit Cousson 	NULL,
708d61649dSBenoit Cousson };
718d61649dSBenoit Cousson 
728d61649dSBenoit Cousson DT_MACHINE_START(OMAP243X_DT, "Generic OMAP2430 (Flattened Device Tree)")
738d61649dSBenoit Cousson 	.reserve	= omap_reserve,
748d61649dSBenoit Cousson 	.map_io		= omap243x_map_io,
758d61649dSBenoit Cousson 	.init_early	= omap2430_init_early,
768d61649dSBenoit Cousson 	.init_machine	= omap_generic_init,
7764dbc3d5STony Lindgren 	.init_time	= omap_init_time_of,
788d61649dSBenoit Cousson 	.dt_compat	= omap243x_boards_compat,
79187e3e06SPaul Walmsley 	.restart	= omap2xxx_restart,
808d61649dSBenoit Cousson MACHINE_END
818d61649dSBenoit Cousson #endif
828d61649dSBenoit Cousson 
830e02a8c1SBenoit Cousson #ifdef CONFIG_ARCH_OMAP3
8471c4f602STony Lindgren /* Some boards need board name for legacy userspace in /proc/cpuinfo */
8571c4f602STony Lindgren static const char *const n900_boards_compat[] __initconst = {
8671c4f602STony Lindgren 	"nokia,omap3-n900",
8771c4f602STony Lindgren 	NULL,
8871c4f602STony Lindgren };
8971c4f602STony Lindgren 
905f35dc47SIvaylo Dimitrov /* Set system_rev from atags */
rx51_set_system_rev(const struct tag * tags)915f35dc47SIvaylo Dimitrov static void __init rx51_set_system_rev(const struct tag *tags)
925f35dc47SIvaylo Dimitrov {
935f35dc47SIvaylo Dimitrov 	const struct tag *tag;
945f35dc47SIvaylo Dimitrov 
955f35dc47SIvaylo Dimitrov 	if (tags->hdr.tag != ATAG_CORE)
965f35dc47SIvaylo Dimitrov 		return;
975f35dc47SIvaylo Dimitrov 
985f35dc47SIvaylo Dimitrov 	for_each_tag(tag, tags) {
995f35dc47SIvaylo Dimitrov 		if (tag->hdr.tag == ATAG_REVISION) {
1005f35dc47SIvaylo Dimitrov 			system_rev = tag->u.revision.rev;
1015f35dc47SIvaylo Dimitrov 			break;
1025f35dc47SIvaylo Dimitrov 		}
1035f35dc47SIvaylo Dimitrov 	}
1045f35dc47SIvaylo Dimitrov }
1055f35dc47SIvaylo Dimitrov 
1068c51b034SIvaylo Dimitrov /* Legacy userspace on Nokia N900 needs ATAGS exported in /proc/atags,
1078c51b034SIvaylo Dimitrov  * save them while the data is still not overwritten
1088c51b034SIvaylo Dimitrov  */
rx51_reserve(void)1098c51b034SIvaylo Dimitrov static void __init rx51_reserve(void)
1108c51b034SIvaylo Dimitrov {
1115f35dc47SIvaylo Dimitrov 	const struct tag *tags = (const struct tag *)(PAGE_OFFSET + 0x100);
1125f35dc47SIvaylo Dimitrov 
1135f35dc47SIvaylo Dimitrov 	save_atags(tags);
1145f35dc47SIvaylo Dimitrov 	rx51_set_system_rev(tags);
1158c51b034SIvaylo Dimitrov 	omap_reserve();
1168c51b034SIvaylo Dimitrov }
1178c51b034SIvaylo Dimitrov 
11871c4f602STony Lindgren DT_MACHINE_START(OMAP3_N900_DT, "Nokia RX-51 board")
1198c51b034SIvaylo Dimitrov 	.reserve	= rx51_reserve,
12071c4f602STony Lindgren 	.map_io		= omap3_map_io,
12171c4f602STony Lindgren 	.init_early	= omap3430_init_early,
12271c4f602STony Lindgren 	.init_machine	= omap_generic_init,
12371c4f602STony Lindgren 	.init_late	= omap3_init_late,
124e428e250STony Lindgren 	.init_time	= omap_init_time_of,
12571c4f602STony Lindgren 	.dt_compat	= n900_boards_compat,
12671c4f602STony Lindgren 	.restart	= omap3xxx_restart,
12771c4f602STony Lindgren MACHINE_END
12871c4f602STony Lindgren 
12971c4f602STony Lindgren /* Generic omap3 boards, most boards can use these */
13058cda01eSUwe Kleine-König static const char *const omap3_boards_compat[] __initconst = {
131b83a08feSNishanth Menon 	"ti,omap3430",
1328d61649dSBenoit Cousson 	"ti,omap3",
1338d61649dSBenoit Cousson 	NULL,
1348d61649dSBenoit Cousson };
1358d61649dSBenoit Cousson 
1368d61649dSBenoit Cousson DT_MACHINE_START(OMAP3_DT, "Generic OMAP3 (Flattened Device Tree)")
1378d61649dSBenoit Cousson 	.reserve	= omap_reserve,
1388d61649dSBenoit Cousson 	.map_io		= omap3_map_io,
1398d61649dSBenoit Cousson 	.init_early	= omap3430_init_early,
14093651b85SBenoit Cousson 	.init_machine	= omap_generic_init,
141990fa4f5SRajendra Nayak 	.init_late	= omap3_init_late,
142e428e250STony Lindgren 	.init_time	= omap_init_time_of,
1438d61649dSBenoit Cousson 	.dt_compat	= omap3_boards_compat,
144187e3e06SPaul Walmsley 	.restart	= omap3xxx_restart,
1458d61649dSBenoit Cousson MACHINE_END
1467dd9d502SJon Hunter 
14758cda01eSUwe Kleine-König static const char *const omap36xx_boards_compat[] __initconst = {
14857df5380STony Lindgren 	"ti,omap3630",
149016c12d2SNishanth Menon 	"ti,omap36xx",
150016c12d2SNishanth Menon 	NULL,
151016c12d2SNishanth Menon };
152016c12d2SNishanth Menon 
153016c12d2SNishanth Menon DT_MACHINE_START(OMAP36XX_DT, "Generic OMAP36xx (Flattened Device Tree)")
154016c12d2SNishanth Menon 	.reserve	= omap_reserve,
155016c12d2SNishanth Menon 	.map_io		= omap3_map_io,
156016c12d2SNishanth Menon 	.init_early	= omap3630_init_early,
157016c12d2SNishanth Menon 	.init_machine	= omap_generic_init,
158016c12d2SNishanth Menon 	.init_late	= omap3_init_late,
159e428e250STony Lindgren 	.init_time	= omap_init_time_of,
160016c12d2SNishanth Menon 	.dt_compat	= omap36xx_boards_compat,
161016c12d2SNishanth Menon 	.restart	= omap3xxx_restart,
162016c12d2SNishanth Menon MACHINE_END
163016c12d2SNishanth Menon 
16458cda01eSUwe Kleine-König static const char *const omap3_gp_boards_compat[] __initconst = {
1657dd9d502SJon Hunter 	"ti,omap3-beagle",
1664bfe6341SAnil Kumar 	"timll,omap3-devkit8000",
1677dd9d502SJon Hunter 	NULL,
1687dd9d502SJon Hunter };
1697dd9d502SJon Hunter 
1707dd9d502SJon Hunter DT_MACHINE_START(OMAP3_GP_DT, "Generic OMAP3-GP (Flattened Device Tree)")
1717dd9d502SJon Hunter 	.reserve	= omap_reserve,
1727dd9d502SJon Hunter 	.map_io		= omap3_map_io,
1737dd9d502SJon Hunter 	.init_early	= omap3430_init_early,
1747dd9d502SJon Hunter 	.init_machine	= omap_generic_init,
175990fa4f5SRajendra Nayak 	.init_late	= omap3_init_late,
176e428e250STony Lindgren 	.init_time	= omap_init_time_of,
1777dd9d502SJon Hunter 	.dt_compat	= omap3_gp_boards_compat,
178d01e4afdSLinus Torvalds 	.restart	= omap3xxx_restart,
1798d61649dSBenoit Cousson MACHINE_END
180caef4ee8SNishanth Menon 
18158cda01eSUwe Kleine-König static const char *const am3517_boards_compat[] __initconst = {
182caef4ee8SNishanth Menon 	"ti,am3517",
183caef4ee8SNishanth Menon 	NULL,
184caef4ee8SNishanth Menon };
185caef4ee8SNishanth Menon 
186caef4ee8SNishanth Menon DT_MACHINE_START(AM3517_DT, "Generic AM3517 (Flattened Device Tree)")
187caef4ee8SNishanth Menon 	.reserve	= omap_reserve,
188caef4ee8SNishanth Menon 	.map_io		= omap3_map_io,
189caef4ee8SNishanth Menon 	.init_early	= am35xx_init_early,
190caef4ee8SNishanth Menon 	.init_machine	= omap_generic_init,
191caef4ee8SNishanth Menon 	.init_late	= omap3_init_late,
192e428e250STony Lindgren 	.init_time	= omap_init_time_of,
193caef4ee8SNishanth Menon 	.dt_compat	= am3517_boards_compat,
194caef4ee8SNishanth Menon 	.restart	= omap3xxx_restart,
195caef4ee8SNishanth Menon MACHINE_END
1968d61649dSBenoit Cousson #endif
1978d61649dSBenoit Cousson 
198abf8cc1dSTony Lindgren #ifdef CONFIG_SOC_TI81XX
199abf8cc1dSTony Lindgren static const char *const ti814x_boards_compat[] __initconst = {
200abf8cc1dSTony Lindgren 	"ti,dm8148",
201abf8cc1dSTony Lindgren 	"ti,dm814",
202abf8cc1dSTony Lindgren 	NULL,
203abf8cc1dSTony Lindgren };
204abf8cc1dSTony Lindgren 
2059fd274c0STony Lindgren DT_MACHINE_START(TI814X_DT, "Generic ti814x (Flattened Device Tree)")
206abf8cc1dSTony Lindgren 	.reserve	= omap_reserve,
207abf8cc1dSTony Lindgren 	.map_io		= ti81xx_map_io,
208abf8cc1dSTony Lindgren 	.init_early	= ti814x_init_early,
209abf8cc1dSTony Lindgren 	.init_machine	= omap_generic_init,
210abf8cc1dSTony Lindgren 	.init_late	= ti81xx_init_late,
21183bd18b4STony Lindgren 	.init_time	= omap_init_time_of,
212abf8cc1dSTony Lindgren 	.dt_compat	= ti814x_boards_compat,
213abf8cc1dSTony Lindgren 	.restart	= ti81xx_restart,
214abf8cc1dSTony Lindgren MACHINE_END
215abf8cc1dSTony Lindgren 
216abf8cc1dSTony Lindgren static const char *const ti816x_boards_compat[] __initconst = {
217abf8cc1dSTony Lindgren 	"ti,dm8168",
218abf8cc1dSTony Lindgren 	"ti,dm816",
219abf8cc1dSTony Lindgren 	NULL,
220abf8cc1dSTony Lindgren };
221abf8cc1dSTony Lindgren 
222abf8cc1dSTony Lindgren DT_MACHINE_START(TI816X_DT, "Generic ti816x (Flattened Device Tree)")
223abf8cc1dSTony Lindgren 	.reserve	= omap_reserve,
224abf8cc1dSTony Lindgren 	.map_io		= ti81xx_map_io,
225abf8cc1dSTony Lindgren 	.init_early	= ti816x_init_early,
226abf8cc1dSTony Lindgren 	.init_machine	= omap_generic_init,
227abf8cc1dSTony Lindgren 	.init_late	= ti81xx_init_late,
22883bd18b4STony Lindgren 	.init_time	= omap_init_time_of,
229abf8cc1dSTony Lindgren 	.dt_compat	= ti816x_boards_compat,
230abf8cc1dSTony Lindgren 	.restart	= ti81xx_restart,
231abf8cc1dSTony Lindgren MACHINE_END
232abf8cc1dSTony Lindgren #endif
233abf8cc1dSTony Lindgren 
23408f30989SAfzal Mohammed #ifdef CONFIG_SOC_AM33XX
23558cda01eSUwe Kleine-König static const char *const am33xx_boards_compat[] __initconst = {
23608f30989SAfzal Mohammed 	"ti,am33xx",
23708f30989SAfzal Mohammed 	NULL,
23808f30989SAfzal Mohammed };
23908f30989SAfzal Mohammed 
24008f30989SAfzal Mohammed DT_MACHINE_START(AM33XX_DT, "Generic AM33XX (Flattened Device Tree)")
24108f30989SAfzal Mohammed 	.reserve	= omap_reserve,
24208f30989SAfzal Mohammed 	.map_io		= am33xx_map_io,
24308f30989SAfzal Mohammed 	.init_early	= am33xx_init_early,
24408f30989SAfzal Mohammed 	.init_machine	= omap_generic_init,
245765e7a06SNishanth Menon 	.init_late	= am33xx_init_late,
246e20ef23dSTony Lindgren 	.init_time	= omap_init_time_of,
24708f30989SAfzal Mohammed 	.dt_compat	= am33xx_boards_compat,
24814e067c1SJean-Sebastien A. Beaudry 	.restart	= am33xx_restart,
24908f30989SAfzal Mohammed MACHINE_END
25008f30989SAfzal Mohammed #endif
25108f30989SAfzal Mohammed 
2520e02a8c1SBenoit Cousson #ifdef CONFIG_ARCH_OMAP4
25358cda01eSUwe Kleine-König static const char *const omap4_boards_compat[] __initconst = {
254b83a08feSNishanth Menon 	"ti,omap4460",
255b83a08feSNishanth Menon 	"ti,omap4430",
2568d61649dSBenoit Cousson 	"ti,omap4",
2578d61649dSBenoit Cousson 	NULL,
2588d61649dSBenoit Cousson };
2598d61649dSBenoit Cousson 
2608d61649dSBenoit Cousson DT_MACHINE_START(OMAP4_DT, "Generic OMAP4 (Flattened Device Tree)")
261944e9df1SMarek Szyprowski 	.l2c_aux_val	= OMAP_L2C_AUX_CTRL,
262944e9df1SMarek Szyprowski 	.l2c_aux_mask	= 0xcf9fffff,
263944e9df1SMarek Szyprowski 	.l2c_write_sec	= omap4_l2c310_write_sec,
2648d61649dSBenoit Cousson 	.reserve	= omap_reserve,
26506915321SMarc Zyngier 	.smp		= smp_ops(omap4_smp_ops),
2668d61649dSBenoit Cousson 	.map_io		= omap4_map_io,
2678d61649dSBenoit Cousson 	.init_early	= omap4430_init_early,
268c4082d49SR Sricharan 	.init_irq	= omap_gic_of_init,
26993651b85SBenoit Cousson 	.init_machine	= omap_generic_init,
270bbd707acSShawn Guo 	.init_late	= omap4430_init_late,
27114b1925aSTony Lindgren 	.init_time	= omap_init_time_of,
2728d61649dSBenoit Cousson 	.dt_compat	= omap4_boards_compat,
273187e3e06SPaul Walmsley 	.restart	= omap44xx_restart,
2748d61649dSBenoit Cousson MACHINE_END
2758d61649dSBenoit Cousson #endif
2760c1b6facSR Sricharan 
2770c1b6facSR Sricharan #ifdef CONFIG_SOC_OMAP5
27858cda01eSUwe Kleine-König static const char *const omap5_boards_compat[] __initconst = {
279b83a08feSNishanth Menon 	"ti,omap5432",
280b83a08feSNishanth Menon 	"ti,omap5430",
2810c1b6facSR Sricharan 	"ti,omap5",
2820c1b6facSR Sricharan 	NULL,
2830c1b6facSR Sricharan };
2840c1b6facSR Sricharan 
2850c1b6facSR Sricharan DT_MACHINE_START(OMAP5_DT, "Generic OMAP5 (Flattened Device Tree)")
2866a3b764bSTony Lindgren #if defined(CONFIG_ZONE_DMA) && defined(CONFIG_ARM_LPAE)
2876a3b764bSTony Lindgren 	.dma_zone_size	= SZ_2G,
2886a3b764bSTony Lindgren #endif
2890c1b6facSR Sricharan 	.reserve	= omap_reserve,
29006915321SMarc Zyngier 	.smp		= smp_ops(omap4_smp_ops),
2910c1b6facSR Sricharan 	.map_io		= omap5_map_io,
2920c1b6facSR Sricharan 	.init_early	= omap5_init_early,
2930c1b6facSR Sricharan 	.init_irq	= omap_gic_of_init,
2940c1b6facSR Sricharan 	.init_machine	= omap_generic_init,
295765e7a06SNishanth Menon 	.init_late	= omap5_init_late,
2966bb27d73SStephen Warren 	.init_time	= omap5_realtime_timer_init,
2970c1b6facSR Sricharan 	.dt_compat	= omap5_boards_compat,
298187e3e06SPaul Walmsley 	.restart	= omap44xx_restart,
2990c1b6facSR Sricharan MACHINE_END
3000c1b6facSR Sricharan #endif
301bb256f80SAfzal Mohammed 
302bb256f80SAfzal Mohammed #ifdef CONFIG_SOC_AM43XX
30358cda01eSUwe Kleine-König static const char *const am43_boards_compat[] __initconst = {
304b83a08feSNishanth Menon 	"ti,am4372",
305bb256f80SAfzal Mohammed 	"ti,am43",
306bb256f80SAfzal Mohammed 	NULL,
307bb256f80SAfzal Mohammed };
308bb256f80SAfzal Mohammed 
309bb256f80SAfzal Mohammed DT_MACHINE_START(AM43_DT, "Generic AM43 (Flattened Device Tree)")
310944e9df1SMarek Szyprowski 	.l2c_aux_val	= OMAP_L2C_AUX_CTRL,
311944e9df1SMarek Szyprowski 	.l2c_aux_mask	= 0xcf9fffff,
312944e9df1SMarek Szyprowski 	.l2c_write_sec	= omap4_l2c310_write_sec,
313bb256f80SAfzal Mohammed 	.map_io		= am33xx_map_io,
314bb256f80SAfzal Mohammed 	.init_early	= am43xx_init_early,
315765e7a06SNishanth Menon 	.init_late	= am43xx_init_late,
316bb256f80SAfzal Mohammed 	.init_irq	= omap_gic_of_init,
317bb256f80SAfzal Mohammed 	.init_machine	= omap_generic_init,
318545a9558STony Lindgren 	.init_time	= omap_init_time_of,
319bb256f80SAfzal Mohammed 	.dt_compat	= am43_boards_compat,
320a7daf64aSLokesh Vutla 	.restart	= omap44xx_restart,
321bb256f80SAfzal Mohammed MACHINE_END
322bb256f80SAfzal Mohammed #endif
323439bf39eSR Sricharan 
324439bf39eSR Sricharan #ifdef CONFIG_SOC_DRA7XX
32558cda01eSUwe Kleine-König static const char *const dra74x_boards_compat[] __initconst = {
3264dc6760dSLokesh Vutla 	"ti,dra762",
3270e0cb99dSNishanth Menon 	"ti,am5728",
3280e0cb99dSNishanth Menon 	"ti,am5726",
32944e97ff6SRajendra Nayak 	"ti,dra742",
330439bf39eSR Sricharan 	"ti,dra7",
331439bf39eSR Sricharan 	NULL,
332439bf39eSR Sricharan };
333439bf39eSR Sricharan 
33444e97ff6SRajendra Nayak DT_MACHINE_START(DRA74X_DT, "Generic DRA74X (Flattened Device Tree)")
3356a3b764bSTony Lindgren #if defined(CONFIG_ZONE_DMA) && defined(CONFIG_ARM_LPAE)
3366a3b764bSTony Lindgren 	.dma_zone_size	= SZ_2G,
3376a3b764bSTony Lindgren #endif
338439bf39eSR Sricharan 	.reserve	= omap_reserve,
339439bf39eSR Sricharan 	.smp		= smp_ops(omap4_smp_ops),
340ea827ad5SNishanth Menon 	.map_io		= dra7xx_map_io,
341439bf39eSR Sricharan 	.init_early	= dra7xx_init_early,
342765e7a06SNishanth Menon 	.init_late	= dra7xx_init_late,
343439bf39eSR Sricharan 	.init_irq	= omap_gic_of_init,
344439bf39eSR Sricharan 	.init_machine	= omap_generic_init,
345439bf39eSR Sricharan 	.init_time	= omap5_realtime_timer_init,
34644e97ff6SRajendra Nayak 	.dt_compat	= dra74x_boards_compat,
34744e97ff6SRajendra Nayak 	.restart	= omap44xx_restart,
34844e97ff6SRajendra Nayak MACHINE_END
34944e97ff6SRajendra Nayak 
35058cda01eSUwe Kleine-König static const char *const dra72x_boards_compat[] __initconst = {
3510e0cb99dSNishanth Menon 	"ti,am5718",
3520e0cb99dSNishanth Menon 	"ti,am5716",
35344e97ff6SRajendra Nayak 	"ti,dra722",
354a2af765aSLokesh Vutla 	"ti,dra718",
35544e97ff6SRajendra Nayak 	NULL,
35644e97ff6SRajendra Nayak };
35744e97ff6SRajendra Nayak 
35844e97ff6SRajendra Nayak DT_MACHINE_START(DRA72X_DT, "Generic DRA72X (Flattened Device Tree)")
3596a3b764bSTony Lindgren #if defined(CONFIG_ZONE_DMA) && defined(CONFIG_ARM_LPAE)
3606a3b764bSTony Lindgren 	.dma_zone_size	= SZ_2G,
3616a3b764bSTony Lindgren #endif
36244e97ff6SRajendra Nayak 	.reserve	= omap_reserve,
363ea827ad5SNishanth Menon 	.map_io		= dra7xx_map_io,
36444e97ff6SRajendra Nayak 	.init_early	= dra7xx_init_early,
36544e97ff6SRajendra Nayak 	.init_late	= dra7xx_init_late,
36644e97ff6SRajendra Nayak 	.init_irq	= omap_gic_of_init,
36744e97ff6SRajendra Nayak 	.init_machine	= omap_generic_init,
36844e97ff6SRajendra Nayak 	.init_time	= omap5_realtime_timer_init,
36944e97ff6SRajendra Nayak 	.dt_compat	= dra72x_boards_compat,
3701d597b07SRajendra Nayak 	.restart	= omap44xx_restart,
371439bf39eSR Sricharan MACHINE_END
372439bf39eSR Sricharan #endif
373