aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-exynos/mach-smdk4x12.c
diff options
context:
space:
mode:
authorSachin Kamat <sachin.kamat@linaro.org>2012-07-13 05:58:53 -0400
committerKukjin Kim <kgene.kim@samsung.com>2012-07-13 05:58:53 -0400
commit6bba0caf5883ebc1430df38551bbb77ce05d4659 (patch)
tree52a75a7a2836cd26a69cecf1d00112358387e241 /arch/arm/mach-exynos/mach-smdk4x12.c
parenta17b985528e280e99bfa918c458583f43b7d8976 (diff)
ARM: EXYNOS: Add framebuffer support for SMDK4X12
This patch adds framebuffer support to SMDK4212 and SMDK4412 boards. A framebuffer window of 480x800x24bpp is defined. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-exynos/mach-smdk4x12.c')
-rw-r--r--arch/arm/mach-exynos/mach-smdk4x12.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/arch/arm/mach-exynos/mach-smdk4x12.c b/arch/arm/mach-exynos/mach-smdk4x12.c
index 61abbc465c54..2623f3bde3f9 100644
--- a/arch/arm/mach-exynos/mach-smdk4x12.c
+++ b/arch/arm/mach-exynos/mach-smdk4x12.c
@@ -13,6 +13,7 @@
13#include <linux/i2c.h> 13#include <linux/i2c.h>
14#include <linux/input.h> 14#include <linux/input.h>
15#include <linux/io.h> 15#include <linux/io.h>
16#include <linux/lcd.h>
16#include <linux/mfd/max8997.h> 17#include <linux/mfd/max8997.h>
17#include <linux/mmc/host.h> 18#include <linux/mmc/host.h>
18#include <linux/platform_device.h> 19#include <linux/platform_device.h>
@@ -29,10 +30,12 @@
29#include <plat/clock.h> 30#include <plat/clock.h>
30#include <plat/cpu.h> 31#include <plat/cpu.h>
31#include <plat/devs.h> 32#include <plat/devs.h>
33#include <plat/fb.h>
32#include <plat/gpio-cfg.h> 34#include <plat/gpio-cfg.h>
33#include <plat/iic.h> 35#include <plat/iic.h>
34#include <plat/keypad.h> 36#include <plat/keypad.h>
35#include <plat/mfc.h> 37#include <plat/mfc.h>
38#include <plat/regs-fb.h>
36#include <plat/regs-serial.h> 39#include <plat/regs-serial.h>
37#include <plat/sdhci.h> 40#include <plat/sdhci.h>
38 41
@@ -237,6 +240,34 @@ static struct samsung_keypad_platdata smdk4x12_keypad_data __initdata = {
237 .cols = 8, 240 .cols = 8,
238}; 241};
239 242
243static struct s3c_fb_pd_win smdk4x12_fb_win0 = {
244 .xres = 480,
245 .yres = 800,
246 .virtual_x = 480,
247 .virtual_y = 800 * 2,
248 .max_bpp = 32,
249 .default_bpp = 24,
250};
251
252static struct fb_videomode smdk4x12_lcd_timing = {
253 .left_margin = 8,
254 .right_margin = 8,
255 .upper_margin = 6,
256 .lower_margin = 6,
257 .hsync_len = 6,
258 .vsync_len = 4,
259 .xres = 480,
260 .yres = 800,
261};
262
263static struct s3c_fb_platdata smdk4x12_lcd_pdata __initdata = {
264 .win[0] = &smdk4x12_fb_win0,
265 .vtiming = &smdk4x12_lcd_timing,
266 .vidcon0 = VIDCON0_VIDOUT_RGB | VIDCON0_PNRMODE_RGB,
267 .vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC,
268 .setup_gpio = exynos4_fimd0_gpio_setup_24bpp,
269};
270
240/* USB OTG */ 271/* USB OTG */
241static struct s3c_hsotg_plat smdk4x12_hsotg_pdata; 272static struct s3c_hsotg_plat smdk4x12_hsotg_pdata;
242 273
@@ -255,6 +286,7 @@ static struct platform_device *smdk4x12_devices[] __initdata = {
255 &s5p_device_fimc2, 286 &s5p_device_fimc2,
256 &s5p_device_fimc3, 287 &s5p_device_fimc3,
257 &s5p_device_fimc_md, 288 &s5p_device_fimc_md,
289 &s5p_device_fimd0,
258 &s5p_device_mfc, 290 &s5p_device_mfc,
259 &s5p_device_mfc_l, 291 &s5p_device_mfc_l,
260 &s5p_device_mfc_r, 292 &s5p_device_mfc_r,
@@ -302,6 +334,8 @@ static void __init smdk4x12_machine_init(void)
302 334
303 s3c_hsotg_set_platdata(&smdk4x12_hsotg_pdata); 335 s3c_hsotg_set_platdata(&smdk4x12_hsotg_pdata);
304 336
337 s5p_fimd0_set_platdata(&smdk4x12_lcd_pdata);
338
305 platform_add_devices(smdk4x12_devices, ARRAY_SIZE(smdk4x12_devices)); 339 platform_add_devices(smdk4x12_devices, ARRAY_SIZE(smdk4x12_devices));
306} 340}
307 341