Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 1 | /* |
| 2 | * Samsung's S3C2416 flattened device tree enabled machine |
| 3 | * |
| 4 | * Copyright (c) 2012 Heiko Stuebner <heiko@sntech.de> |
| 5 | * |
| 6 | * based on mach-exynos/mach-exynos4-dt.c |
| 7 | * |
| 8 | * Copyright (c) 2010-2011 Samsung Electronics Co., Ltd. |
| 9 | * http://www.samsung.com |
| 10 | * Copyright (c) 2010-2011 Linaro Ltd. |
| 11 | * www.linaro.org |
| 12 | * |
| 13 | * This program is free software; you can redistribute it and/or modify |
| 14 | * it under the terms of the GNU General Public License version 2 as |
| 15 | * published by the Free Software Foundation. |
| 16 | */ |
| 17 | |
| 18 | #include <linux/clocksource.h> |
| 19 | #include <linux/irqchip.h> |
| 20 | #include <linux/of_platform.h> |
Tushar Behera | 334a1c7 | 2014-02-14 10:32:45 +0900 | [diff] [blame] | 21 | #include <linux/serial_s3c.h> |
Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 22 | |
| 23 | #include <asm/mach/arch.h> |
| 24 | #include <mach/map.h> |
| 25 | |
| 26 | #include <plat/cpu.h> |
| 27 | #include <plat/pm.h> |
Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 28 | |
| 29 | #include "common.h" |
| 30 | |
Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 31 | static void __init s3c2416_dt_map_io(void) |
| 32 | { |
| 33 | s3c24xx_init_io(NULL, 0); |
Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 34 | } |
| 35 | |
| 36 | static void __init s3c2416_dt_machine_init(void) |
| 37 | { |
Heiko Stuebner | dfc0f50 | 2014-02-19 09:26:21 +0900 | [diff] [blame] | 38 | of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); |
Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 39 | s3c_pm_init(); |
| 40 | } |
| 41 | |
| 42 | static char const *s3c2416_dt_compat[] __initdata = { |
| 43 | "samsung,s3c2416", |
| 44 | "samsung,s3c2450", |
| 45 | NULL |
| 46 | }; |
| 47 | |
| 48 | DT_MACHINE_START(S3C2416_DT, "Samsung S3C2416 (Flattened Device Tree)") |
| 49 | /* Maintainer: Heiko Stuebner <heiko@sntech.de> */ |
| 50 | .dt_compat = s3c2416_dt_compat, |
| 51 | .map_io = s3c2416_dt_map_io, |
| 52 | .init_irq = irqchip_init, |
| 53 | .init_machine = s3c2416_dt_machine_init, |
Heiko Stuebner | 35aca36 | 2013-05-21 01:06:04 +0900 | [diff] [blame] | 54 | MACHINE_END |