diff options
author | Marek Szyprowski <m.szyprowski@samsung.com> | 2010-07-14 06:38:18 -0400 |
---|---|---|
committer | Kukjin Kim <kgene.kim@samsung.com> | 2010-08-05 05:31:00 -0400 |
commit | 3965fdee7723d01e97861cabf13c5cb8824cb4e6 (patch) | |
tree | 0ad5808bb524bc096ab9275a5f4ed067722e4214 /arch/arm/mach-s5pv210/mach-goni.c | |
parent | 9c8dc1a88c760ec121a260afc9583ec9239497ef (diff) |
ARM: S5PV210: Add Framebuffer support for GONI
This patch adds required platform definitions to enable s3c-fb
driver on GONI board. One framebuffer window in 480x800x16bpp mode is
defined.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
[kgene.kim@samsung.com: minor title fix]
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-s5pv210/mach-goni.c')
-rw-r--r-- | arch/arm/mach-s5pv210/mach-goni.c | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c index 88c38e313aa8..bec488e5d23c 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c +++ b/arch/arm/mach-s5pv210/mach-goni.c | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <linux/types.h> | 12 | #include <linux/types.h> |
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/serial_core.h> | 14 | #include <linux/serial_core.h> |
15 | #include <linux/fb.h> | ||
15 | 16 | ||
16 | #include <asm/mach/arch.h> | 17 | #include <asm/mach/arch.h> |
17 | #include <asm/mach/map.h> | 18 | #include <asm/mach/map.h> |
@@ -20,11 +21,13 @@ | |||
20 | 21 | ||
21 | #include <mach/map.h> | 22 | #include <mach/map.h> |
22 | #include <mach/regs-clock.h> | 23 | #include <mach/regs-clock.h> |
24 | #include <mach/regs-fb.h> | ||
23 | 25 | ||
24 | #include <plat/regs-serial.h> | 26 | #include <plat/regs-serial.h> |
25 | #include <plat/s5pv210.h> | 27 | #include <plat/s5pv210.h> |
26 | #include <plat/devs.h> | 28 | #include <plat/devs.h> |
27 | #include <plat/cpu.h> | 29 | #include <plat/cpu.h> |
30 | #include <plat/fb.h> | ||
28 | 31 | ||
29 | /* Following are default values for UCON, ULCON and UFCON UART registers */ | 32 | /* Following are default values for UCON, ULCON and UFCON UART registers */ |
30 | #define S5PV210_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \ | 33 | #define S5PV210_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \ |
@@ -73,7 +76,35 @@ static struct s3c2410_uartcfg goni_uartcfgs[] __initdata = { | |||
73 | }, | 76 | }, |
74 | }; | 77 | }; |
75 | 78 | ||
79 | /* Frame Buffer */ | ||
80 | static struct s3c_fb_pd_win goni_fb_win0 = { | ||
81 | .win_mode = { | ||
82 | .pixclock = 1000000000000ULL / ((16+16+2+480)*(28+3+2+800)*55), | ||
83 | .left_margin = 16, | ||
84 | .right_margin = 16, | ||
85 | .upper_margin = 3, | ||
86 | .lower_margin = 28, | ||
87 | .hsync_len = 2, | ||
88 | .vsync_len = 2, | ||
89 | .xres = 480, | ||
90 | .yres = 800, | ||
91 | .refresh = 55, | ||
92 | }, | ||
93 | .max_bpp = 32, | ||
94 | .default_bpp = 16, | ||
95 | }; | ||
96 | |||
97 | static struct s3c_fb_platdata goni_lcd_pdata __initdata = { | ||
98 | .win[0] = &goni_fb_win0, | ||
99 | .vidcon0 = VIDCON0_VIDOUT_RGB | VIDCON0_PNRMODE_RGB | | ||
100 | VIDCON0_CLKSEL_LCD, | ||
101 | .vidcon1 = VIDCON1_INV_VCLK | VIDCON1_INV_VDEN | ||
102 | | VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC, | ||
103 | .setup_gpio = s5pv210_fb_gpio_setup_24bpp, | ||
104 | }; | ||
105 | |||
76 | static struct platform_device *goni_devices[] __initdata = { | 106 | static struct platform_device *goni_devices[] __initdata = { |
107 | &s3c_device_fb, | ||
77 | &s5pc110_device_onenand, | 108 | &s5pc110_device_onenand, |
78 | }; | 109 | }; |
79 | 110 | ||
@@ -86,6 +117,9 @@ static void __init goni_map_io(void) | |||
86 | 117 | ||
87 | static void __init goni_machine_init(void) | 118 | static void __init goni_machine_init(void) |
88 | { | 119 | { |
120 | /* FB */ | ||
121 | s3c_fb_set_platdata(&goni_lcd_pdata); | ||
122 | |||
89 | platform_add_devices(goni_devices, ARRAY_SIZE(goni_devices)); | 123 | platform_add_devices(goni_devices, ARRAY_SIZE(goni_devices)); |
90 | } | 124 | } |
91 | 125 | ||