diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2013-02-08 16:58:17 -0500 |
---|---|---|
committer | Kukjin Kim <kgene.kim@samsung.com> | 2013-03-07 05:41:36 -0500 |
commit | 20901f74e16965cbeb1f6cdc282140fc0bafd28f (patch) | |
tree | 5ab348bdc3e386effc19609378639a85717a8ba5 /arch | |
parent | 43afcbad76f3cdd8e33f6edb1fca340c1b9c55b2 (diff) |
ARM: dts: Add MFC codec support for EXYNOS4 DT machines
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Tested-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/boot/dts/exynos4.dtsi | 8 | ||||
-rw-r--r-- | arch/arm/mach-exynos/Kconfig | 1 | ||||
-rw-r--r-- | arch/arm/mach-exynos/mach-exynos4-dt.c | 17 |
3 files changed, 26 insertions, 0 deletions
diff --git a/arch/arm/boot/dts/exynos4.dtsi b/arch/arm/boot/dts/exynos4.dtsi index e1347fceb5bc..6581bb2252e7 100644 --- a/arch/arm/boot/dts/exynos4.dtsi +++ b/arch/arm/boot/dts/exynos4.dtsi | |||
@@ -131,6 +131,14 @@ | |||
131 | status = "disabled"; | 131 | status = "disabled"; |
132 | }; | 132 | }; |
133 | 133 | ||
134 | mfc: codec@13400000 { | ||
135 | compatible = "samsung,mfc-v5"; | ||
136 | reg = <0x13400000 0x10000>; | ||
137 | interrupts = <0 94 0>; | ||
138 | samsung,power-domain = <&pd_mfc>; | ||
139 | status = "disabled"; | ||
140 | }; | ||
141 | |||
134 | serial@13800000 { | 142 | serial@13800000 { |
135 | compatible = "samsung,exynos4210-uart"; | 143 | compatible = "samsung,exynos4210-uart"; |
136 | reg = <0x13800000 0x100>; | 144 | reg = <0x13800000 0x100>; |
diff --git a/arch/arm/mach-exynos/Kconfig b/arch/arm/mach-exynos/Kconfig index 70f94c87479d..78bd3479c7e1 100644 --- a/arch/arm/mach-exynos/Kconfig +++ b/arch/arm/mach-exynos/Kconfig | |||
@@ -410,6 +410,7 @@ config MACH_EXYNOS4_DT | |||
410 | select HAVE_SAMSUNG_KEYPAD if INPUT_KEYBOARD | 410 | select HAVE_SAMSUNG_KEYPAD if INPUT_KEYBOARD |
411 | select PINCTRL | 411 | select PINCTRL |
412 | select PINCTRL_EXYNOS | 412 | select PINCTRL_EXYNOS |
413 | select S5P_DEV_MFC | ||
413 | select USE_OF | 414 | select USE_OF |
414 | help | 415 | help |
415 | Machine support for Samsung Exynos4 machine with device tree enabled. | 416 | Machine support for Samsung Exynos4 machine with device tree enabled. |
diff --git a/arch/arm/mach-exynos/mach-exynos4-dt.c b/arch/arm/mach-exynos/mach-exynos4-dt.c index 3358088c822a..fad268f8548c 100644 --- a/arch/arm/mach-exynos/mach-exynos4-dt.c +++ b/arch/arm/mach-exynos/mach-exynos4-dt.c | |||
@@ -12,13 +12,16 @@ | |||
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/of_platform.h> | 14 | #include <linux/of_platform.h> |
15 | #include <linux/of_fdt.h> | ||
15 | #include <linux/serial_core.h> | 16 | #include <linux/serial_core.h> |
17 | #include <linux/memblock.h> | ||
16 | 18 | ||
17 | #include <asm/mach/arch.h> | 19 | #include <asm/mach/arch.h> |
18 | #include <mach/map.h> | 20 | #include <mach/map.h> |
19 | 21 | ||
20 | #include <plat/cpu.h> | 22 | #include <plat/cpu.h> |
21 | #include <plat/regs-serial.h> | 23 | #include <plat/regs-serial.h> |
24 | #include <plat/mfc.h> | ||
22 | 25 | ||
23 | #include "common.h" | 26 | #include "common.h" |
24 | 27 | ||
@@ -113,6 +116,7 @@ static const struct of_dev_auxdata exynos4_auxdata_lookup[] __initconst = { | |||
113 | "exynos-sysmmu.14", NULL), /* FIMC-LITE0(4x12) */ | 116 | "exynos-sysmmu.14", NULL), /* FIMC-LITE0(4x12) */ |
114 | OF_DEV_AUXDATA("samsung,exynos-sysmmu", 0x123C0000, | 117 | OF_DEV_AUXDATA("samsung,exynos-sysmmu", 0x123C0000, |
115 | "exynos-sysmmu.15", NULL), /* FIMC-LITE1(4x12) */ | 118 | "exynos-sysmmu.15", NULL), /* FIMC-LITE1(4x12) */ |
119 | OF_DEV_AUXDATA("samsung,mfc-v5", 0x13400000, "s5p-mfc", NULL), | ||
116 | {}, | 120 | {}, |
117 | }; | 121 | }; |
118 | 122 | ||
@@ -135,6 +139,18 @@ static char const *exynos4_dt_compat[] __initdata = { | |||
135 | NULL | 139 | NULL |
136 | }; | 140 | }; |
137 | 141 | ||
142 | static void __init exynos4_reserve(void) | ||
143 | { | ||
144 | #ifdef CONFIG_S5P_DEV_MFC | ||
145 | struct s5p_mfc_dt_meminfo mfc_mem; | ||
146 | |||
147 | /* Reserve memory for MFC only if it's available */ | ||
148 | mfc_mem.compatible = "samsung,mfc-v5"; | ||
149 | if (of_scan_flat_dt(s5p_fdt_find_mfc_mem, &mfc_mem)) | ||
150 | s5p_mfc_reserve_mem(mfc_mem.roff, mfc_mem.rsize, mfc_mem.loff, | ||
151 | mfc_mem.lsize); | ||
152 | #endif | ||
153 | } | ||
138 | DT_MACHINE_START(EXYNOS4210_DT, "Samsung Exynos4 (Flattened Device Tree)") | 154 | DT_MACHINE_START(EXYNOS4210_DT, "Samsung Exynos4 (Flattened Device Tree)") |
139 | /* Maintainer: Thomas Abraham <thomas.abraham@linaro.org> */ | 155 | /* Maintainer: Thomas Abraham <thomas.abraham@linaro.org> */ |
140 | .smp = smp_ops(exynos_smp_ops), | 156 | .smp = smp_ops(exynos_smp_ops), |
@@ -145,4 +161,5 @@ DT_MACHINE_START(EXYNOS4210_DT, "Samsung Exynos4 (Flattened Device Tree)") | |||
145 | .init_time = exynos4_timer_init, | 161 | .init_time = exynos4_timer_init, |
146 | .dt_compat = exynos4_dt_compat, | 162 | .dt_compat = exynos4_dt_compat, |
147 | .restart = exynos4_restart, | 163 | .restart = exynos4_restart, |
164 | .reserve = exynos4_reserve, | ||
148 | MACHINE_END | 165 | MACHINE_END |