diff options
author | Krzysztof Helt <krzysztof.h1@wp.pl> | 2007-10-16 04:28:56 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-16 12:43:16 -0400 |
commit | 09fe75f6f934597f765748342ca6fb378ee7ecdb (patch) | |
tree | 55a3ab7bf52400be136ec533cd5ebda4336fcd07 /arch/arm/mach-s3c2440/mach-smdk2440.c | |
parent | 110c1fa75463c4f327e9fc491e9a27e938800d96 (diff) |
s3c2410fb: multi-display support
This patch adds a new structure to describe and handle
more than one panel (display mode) for the s3c2410 framebuffer.
This structure is added after the pxafb driver.
Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/arm/mach-s3c2440/mach-smdk2440.c')
-rw-r--r-- | arch/arm/mach-s3c2440/mach-smdk2440.c | 41 |
1 files changed, 17 insertions, 24 deletions
diff --git a/arch/arm/mach-s3c2440/mach-smdk2440.c b/arch/arm/mach-s3c2440/mach-smdk2440.c index 670115b8a12e..f7dac7d54064 100644 --- a/arch/arm/mach-s3c2440/mach-smdk2440.c +++ b/arch/arm/mach-s3c2440/mach-smdk2440.c | |||
@@ -103,7 +103,7 @@ static struct s3c2410_uartcfg smdk2440_uartcfgs[] __initdata = { | |||
103 | 103 | ||
104 | /* LCD driver info */ | 104 | /* LCD driver info */ |
105 | 105 | ||
106 | static struct s3c2410fb_mach_info smdk2440_lcd_cfg __initdata = { | 106 | static struct s3c2410fb_display smdk2440_lcd_cfg __initdata = { |
107 | .regs = { | 107 | .regs = { |
108 | 108 | ||
109 | .lcdcon1 = S3C2410_LCDCON1_TFT16BPP | | 109 | .lcdcon1 = S3C2410_LCDCON1_TFT16BPP | |
@@ -129,6 +129,21 @@ static struct s3c2410fb_mach_info smdk2440_lcd_cfg __initdata = { | |||
129 | S3C2410_LCDCON5_HWSWP, | 129 | S3C2410_LCDCON5_HWSWP, |
130 | }, | 130 | }, |
131 | 131 | ||
132 | .type = S3C2410_LCDCON1_TFT16BPP, | ||
133 | |||
134 | .width = 240, | ||
135 | .height = 320, | ||
136 | |||
137 | .xres = 240, | ||
138 | .yres = 320, | ||
139 | .bpp = 16, | ||
140 | }; | ||
141 | |||
142 | static struct s3c2410fb_mach_info smdk2440_fb_info __initdata = { | ||
143 | .displays = &smdk2440_lcd_cfg, | ||
144 | .num_displays = 1, | ||
145 | .default_display = 0, | ||
146 | |||
132 | #if 0 | 147 | #if 0 |
133 | /* currently setup by downloader */ | 148 | /* currently setup by downloader */ |
134 | .gpccon = 0xaa940659, | 149 | .gpccon = 0xaa940659, |
@@ -142,28 +157,6 @@ static struct s3c2410fb_mach_info smdk2440_lcd_cfg __initdata = { | |||
142 | #endif | 157 | #endif |
143 | 158 | ||
144 | .lpcsel = ((0xCE6) & ~7) | 1<<4, | 159 | .lpcsel = ((0xCE6) & ~7) | 1<<4, |
145 | .type = S3C2410_LCDCON1_TFT16BPP, | ||
146 | |||
147 | .width = 240, | ||
148 | .height = 320, | ||
149 | |||
150 | .xres = { | ||
151 | .min = 240, | ||
152 | .max = 240, | ||
153 | .defval = 240, | ||
154 | }, | ||
155 | |||
156 | .yres = { | ||
157 | .min = 320, | ||
158 | .max = 320, | ||
159 | .defval = 320, | ||
160 | }, | ||
161 | |||
162 | .bpp = { | ||
163 | .min = 16, | ||
164 | .max = 16, | ||
165 | .defval = 16, | ||
166 | }, | ||
167 | }; | 160 | }; |
168 | 161 | ||
169 | static struct platform_device *smdk2440_devices[] __initdata = { | 162 | static struct platform_device *smdk2440_devices[] __initdata = { |
@@ -183,7 +176,7 @@ static void __init smdk2440_map_io(void) | |||
183 | 176 | ||
184 | static void __init smdk2440_machine_init(void) | 177 | static void __init smdk2440_machine_init(void) |
185 | { | 178 | { |
186 | s3c24xx_fb_set_platdata(&smdk2440_lcd_cfg); | 179 | s3c24xx_fb_set_platdata(&smdk2440_fb_info); |
187 | 180 | ||
188 | platform_add_devices(smdk2440_devices, ARRAY_SIZE(smdk2440_devices)); | 181 | platform_add_devices(smdk2440_devices, ARRAY_SIZE(smdk2440_devices)); |
189 | smdk_machine_init(); | 182 | smdk_machine_init(); |