2011-11-06 17:24:27 +01:00
|
|
|
/*
|
2012-09-21 03:13:29 +02:00
|
|
|
* Samsung's EXYNOS4 flattened device tree enabled machine
|
2011-11-06 17:24:27 +01:00
|
|
|
*
|
|
|
|
* Copyright (c) 2010-2011 Samsung Electronics Co., Ltd.
|
|
|
|
* http://www.samsung.com
|
|
|
|
* Copyright (c) 2010-2011 Linaro Ltd.
|
|
|
|
* www.linaro.org
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
|
|
* published by the Free Software Foundation.
|
|
|
|
*/
|
|
|
|
|
2013-03-09 09:10:23 +01:00
|
|
|
#include <linux/kernel.h>
|
2011-11-06 17:24:27 +01:00
|
|
|
#include <linux/of_platform.h>
|
2013-02-08 22:58:17 +01:00
|
|
|
#include <linux/of_fdt.h>
|
2011-11-06 17:24:27 +01:00
|
|
|
#include <linux/serial_core.h>
|
2013-02-08 22:58:17 +01:00
|
|
|
#include <linux/memblock.h>
|
2013-03-09 08:10:03 +01:00
|
|
|
#include <linux/clocksource.h>
|
2011-11-06 17:24:27 +01:00
|
|
|
|
|
|
|
#include <asm/mach/arch.h>
|
2013-02-08 22:58:17 +01:00
|
|
|
#include <plat/mfc.h>
|
2012-02-08 03:42:39 +01:00
|
|
|
|
|
|
|
#include "common.h"
|
2011-11-06 17:24:27 +01:00
|
|
|
|
2012-09-21 03:13:29 +02:00
|
|
|
static void __init exynos4_dt_machine_init(void)
|
2011-11-06 17:24:27 +01:00
|
|
|
{
|
2013-03-09 09:10:23 +01:00
|
|
|
of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
|
2011-11-06 17:24:27 +01:00
|
|
|
}
|
|
|
|
|
2012-09-21 03:13:29 +02:00
|
|
|
static char const *exynos4_dt_compat[] __initdata = {
|
2011-11-06 17:24:27 +01:00
|
|
|
"samsung,exynos4210",
|
2012-11-06 07:09:04 +01:00
|
|
|
"samsung,exynos4212",
|
|
|
|
"samsung,exynos4412",
|
2011-11-06 17:24:27 +01:00
|
|
|
NULL
|
|
|
|
};
|
|
|
|
|
2013-02-08 22:58:17 +01:00
|
|
|
static void __init exynos4_reserve(void)
|
|
|
|
{
|
|
|
|
#ifdef CONFIG_S5P_DEV_MFC
|
|
|
|
struct s5p_mfc_dt_meminfo mfc_mem;
|
|
|
|
|
|
|
|
/* Reserve memory for MFC only if it's available */
|
|
|
|
mfc_mem.compatible = "samsung,mfc-v5";
|
|
|
|
if (of_scan_flat_dt(s5p_fdt_find_mfc_mem, &mfc_mem))
|
|
|
|
s5p_mfc_reserve_mem(mfc_mem.roff, mfc_mem.rsize, mfc_mem.loff,
|
|
|
|
mfc_mem.lsize);
|
|
|
|
#endif
|
|
|
|
}
|
2011-11-06 17:24:27 +01:00
|
|
|
DT_MACHINE_START(EXYNOS4210_DT, "Samsung Exynos4 (Flattened Device Tree)")
|
|
|
|
/* Maintainer: Thomas Abraham <thomas.abraham@linaro.org> */
|
2012-10-22 01:16:44 +02:00
|
|
|
.smp = smp_ops(exynos_smp_ops),
|
2013-06-18 18:36:47 +02:00
|
|
|
.map_io = exynos_init_io,
|
2012-12-11 05:58:43 +01:00
|
|
|
.init_early = exynos_firmware_init,
|
2012-09-21 03:13:29 +02:00
|
|
|
.init_machine = exynos4_dt_machine_init,
|
2012-04-26 04:35:40 +02:00
|
|
|
.init_late = exynos_init_late,
|
2013-03-09 09:03:29 +01:00
|
|
|
.init_time = exynos_init_time,
|
2012-09-21 03:13:29 +02:00
|
|
|
.dt_compat = exynos4_dt_compat,
|
2012-02-08 03:42:39 +01:00
|
|
|
.restart = exynos4_restart,
|
2013-02-08 22:58:17 +01:00
|
|
|
.reserve = exynos4_reserve,
|
2011-11-06 17:24:27 +01:00
|
|
|
MACHINE_END
|