aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-exynos4
diff options
context:
space:
mode:
authorGiridhar Maruthy <giridhar.maruthy@linaro.org>2011-08-31 02:58:52 -0400
committerKukjin Kim <kgene.kim@samsung.com>2011-10-02 19:42:22 -0400
commit9edff0f79f5b98e6abfabfa27b31d155e3c994e1 (patch)
treeaab66bee21154b8bc45174526769c4529d6acc86 /arch/arm/mach-exynos4
parent6f8eb324a395da5bd0c0b113944f2906272e14bd (diff)
ARM: EXYNOS4: Add PWM backlight support on ORIGEN
This patch adds support for LCD backlight using PWM timer on ORIGEN board. Signed-off-by: Giridhar Maruthy <giridhar.maruthy@linaro.org> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-exynos4')
-rw-r--r--arch/arm/mach-exynos4/Kconfig2
-rw-r--r--arch/arm/mach-exynos4/mach-origen.c16
2 files changed, 18 insertions, 0 deletions
diff --git a/arch/arm/mach-exynos4/Kconfig b/arch/arm/mach-exynos4/Kconfig
index 9c920b2acc36..86cf4fd47b35 100644
--- a/arch/arm/mach-exynos4/Kconfig
+++ b/arch/arm/mach-exynos4/Kconfig
@@ -229,6 +229,8 @@ config MACH_ORIGEN
229 select S5P_DEV_FIMC2 229 select S5P_DEV_FIMC2
230 select S5P_DEV_FIMC3 230 select S5P_DEV_FIMC3
231 select S5P_DEV_USB_EHCI 231 select S5P_DEV_USB_EHCI
232 select SAMSUNG_DEV_BACKLIGHT
233 select SAMSUNG_DEV_PWM
232 select EXYNOS4_SETUP_SDHCI 234 select EXYNOS4_SETUP_SDHCI
233 select EXYNOS4_SETUP_USB_PHY 235 select EXYNOS4_SETUP_USB_PHY
234 help 236 help
diff --git a/arch/arm/mach-exynos4/mach-origen.c b/arch/arm/mach-exynos4/mach-origen.c
index 7ac71878767b..937db75688d0 100644
--- a/arch/arm/mach-exynos4/mach-origen.c
+++ b/arch/arm/mach-exynos4/mach-origen.c
@@ -14,6 +14,7 @@
14#include <linux/platform_device.h> 14#include <linux/platform_device.h>
15#include <linux/io.h> 15#include <linux/io.h>
16#include <linux/input.h> 16#include <linux/input.h>
17#include <linux/pwm_backlight.h>
17 18
18#include <asm/mach/arch.h> 19#include <asm/mach/arch.h>
19#include <asm/mach-types.h> 20#include <asm/mach-types.h>
@@ -26,6 +27,8 @@
26#include <plat/iic.h> 27#include <plat/iic.h>
27#include <plat/ehci.h> 28#include <plat/ehci.h>
28#include <plat/clock.h> 29#include <plat/clock.h>
30#include <plat/gpio-cfg.h>
31#include <plat/backlight.h>
29 32
30#include <mach/map.h> 33#include <mach/map.h>
31 34
@@ -102,6 +105,17 @@ static struct platform_device *origen_devices[] __initdata = {
102 &s5p_device_fimc3, 105 &s5p_device_fimc3,
103}; 106};
104 107
108/* LCD Backlight data */
109static struct samsung_bl_gpio_info origen_bl_gpio_info = {
110 .no = EXYNOS4_GPD0(0),
111 .func = S3C_GPIO_SFN(2),
112};
113
114static struct platform_pwm_backlight_data origen_bl_data = {
115 .pwm_id = 0,
116 .pwm_period_ns = 1000,
117};
118
105static void __init origen_map_io(void) 119static void __init origen_map_io(void)
106{ 120{
107 s5p_init_io(NULL, 0, S5P_VA_CHIPID); 121 s5p_init_io(NULL, 0, S5P_VA_CHIPID);
@@ -117,6 +131,8 @@ static void __init origen_machine_init(void)
117 clk_xusbxti.rate = 24000000; 131 clk_xusbxti.rate = 24000000;
118 132
119 platform_add_devices(origen_devices, ARRAY_SIZE(origen_devices)); 133 platform_add_devices(origen_devices, ARRAY_SIZE(origen_devices));
134
135 samsung_bl_set(&origen_bl_gpio_info, &origen_bl_data);
120} 136}
121 137
122MACHINE_START(ORIGEN, "ORIGEN") 138MACHINE_START(ORIGEN, "ORIGEN")