aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Schurig <hs4233@mail.mn-solutions.de>2009-01-26 10:34:56 -0500
committerSascha Hauer <s.hauer@pengutronix.de>2009-03-13 05:33:55 -0400
commite48135519bd569eed374e0e17ed5233d4105fa97 (patch)
tree5a43bdc795646d6883ab9aaa75cbcb6b6e0b74c0
parentaa3b0a6f57be50f1009a409e82731a8f9be80fc4 (diff)
arm/imx21: Framebuffer support for i.MX21
This patch mimicks what Martin wrote on the mailing list: * move arch/arm/mach-imx/include/mach/imxfb.h into arch/arm/mach-mxc/include/mach/imxfb.h * changes Kconfig so that CONFIG_FB_IMX is selectable * adds a platform device (copied from some pengutronix patches) Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
-rw-r--r--arch/arm/mach-mx2/devices.c33
-rw-r--r--arch/arm/mach-mx2/devices.h2
-rw-r--r--arch/arm/plat-mxc/include/mach/imxfb.h (renamed from arch/arm/mach-imx/include/mach/imxfb.h)0
-rw-r--r--drivers/video/Kconfig2
4 files changed, 35 insertions, 2 deletions
diff --git a/arch/arm/mach-mx2/devices.c b/arch/arm/mach-mx2/devices.c
index 9ddd6d061058..07061e644545 100644
--- a/arch/arm/mach-mx2/devices.c
+++ b/arch/arm/mach-mx2/devices.c
@@ -228,6 +228,39 @@ struct platform_device mxc_nand_device = {
228 .resource = mxc_nand_resources, 228 .resource = mxc_nand_resources,
229}; 229};
230 230
231#ifdef CONFIG_FB_IMX
232/*
233 * lcdc:
234 * - i.MX1: the basic controller
235 * - i.MX21: to be checked
236 * - i.MX27: like i.MX1, with slightly variations
237 */
238static struct resource mxc_fb[] = {
239 {
240 .start = LCDC_BASE_ADDR,
241 .end = LCDC_BASE_ADDR + 0xFFF,
242 .flags = IORESOURCE_MEM,
243 },
244 {
245 .start = MXC_INT_LCDC,
246 .end = MXC_INT_LCDC,
247 .flags = IORESOURCE_IRQ,
248 }
249};
250
251/* mxc lcd driver */
252struct platform_device mxc_fb_device = {
253 .name = "imx-fb",
254 .id = 0,
255 .num_resources = ARRAY_SIZE(mxc_fb),
256 .resource = mxc_fb,
257 .dev = {
258 .coherent_dma_mask = 0xFFFFFFFF,
259 },
260};
261
262#endif
263
231/* GPIO port description */ 264/* GPIO port description */
232static struct mxc_gpio_port imx_gpio_ports[] = { 265static struct mxc_gpio_port imx_gpio_ports[] = {
233 [0] = { 266 [0] = {
diff --git a/arch/arm/mach-mx2/devices.h b/arch/arm/mach-mx2/devices.h
index 1e8cb577a642..f4cb0ce29f13 100644
--- a/arch/arm/mach-mx2/devices.h
+++ b/arch/arm/mach-mx2/devices.h
@@ -1,4 +1,3 @@
1
2extern struct platform_device mxc_gpt1; 1extern struct platform_device mxc_gpt1;
3extern struct platform_device mxc_gpt2; 2extern struct platform_device mxc_gpt2;
4extern struct platform_device mxc_gpt3; 3extern struct platform_device mxc_gpt3;
@@ -14,3 +13,4 @@ extern struct platform_device mxc_uart_device4;
14extern struct platform_device mxc_uart_device5; 13extern struct platform_device mxc_uart_device5;
15extern struct platform_device mxc_w1_master_device; 14extern struct platform_device mxc_w1_master_device;
16extern struct platform_device mxc_nand_device; 15extern struct platform_device mxc_nand_device;
16extern struct platform_device mxc_fb_device;
diff --git a/arch/arm/mach-imx/include/mach/imxfb.h b/arch/arm/plat-mxc/include/mach/imxfb.h
index 870d0d939616..870d0d939616 100644
--- a/arch/arm/mach-imx/include/mach/imxfb.h
+++ b/arch/arm/plat-mxc/include/mach/imxfb.h
diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index fb19803060cf..967ac3d359a6 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -397,7 +397,7 @@ config FB_SA1100
397 397
398config FB_IMX 398config FB_IMX
399 tristate "Motorola i.MX LCD support" 399 tristate "Motorola i.MX LCD support"
400 depends on FB && ARM && ARCH_IMX 400 depends on FB && (ARCH_IMX || ARCH_MX2)
401 select FB_CFB_FILLRECT 401 select FB_CFB_FILLRECT
402 select FB_CFB_COPYAREA 402 select FB_CFB_COPYAREA
403 select FB_CFB_IMAGEBLIT 403 select FB_CFB_IMAGEBLIT