From: Andrei Konovalov <akonovalov@ru.mvista.com>
To: linuxppc-embedded@ozlabs.org
Cc: Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH] Xilinx framebuffer device driver - 3d version
Date: Thu, 03 May 2007 21:29:16 +0400 [thread overview]
Message-ID: <463A1BEC.4040700@ru.mvista.com> (raw)
In-Reply-To: <463A1B58.8000804@ru.mvista.com>
[-- Attachment #1: Type: text/plain, Size: 648 bytes --]
Hello,
Andrei Konovalov wrote:
> Add support for the video controller IP block included into Xilinx ML300
> and ML403 reference designs.
>
> Signed-off-by: Andrei Konovalov <akonovalov@ru.mvista.com>
>
> -----
> The driver has been tested with Xilinx ML300 and ML403 reference designs.
>
> The two first version has been posted to linuxppc-embedded, and this
> version tries to address all the comments and criticism received.
>
> The platform device registration for Xilinx ML300 and ML403
> moved into separate patch (will be posted to linuxppc-embedded
> in couple minutes).
Here is the platform device registration part.
Thanks,
Andrei
[-- Attachment #2: ppc32-enable-xilinx_fb.patch --]
[-- Type: text/x-patch, Size: 2684 bytes --]
Index: linux-2.6.20/arch/ppc/platforms/4xx/xilinx_ml403.c
===================================================================
--- linux-2.6.20.orig/arch/ppc/platforms/4xx/xilinx_ml403.c
+++ linux-2.6.20/arch/ppc/platforms/4xx/xilinx_ml403.c
@@ -118,3 +118,20 @@ platform_init(unsigned long r3, unsigned
#endif
}
+static struct xilinxfb_platform_data xilinxfb_ml403_pdata = {
+ .rotate_screen = 0,
+ .screen_height_mm = -1,
+ .screen_width_mm = -1,
+};
+
+int __init virtex_device_fixup(struct platform_device *dev)
+{
+ if (strcmp(dev->name, "xilinxfb") == 0) {
+ if (dev->id != 0) /* paranoic */
+ return 1;
+ dev->dev.platform_data = &xilinxfb_ml403_pdata;
+ return 0;
+ }
+ return 0;
+}
+
Index: linux-2.6.20/arch/ppc/platforms/4xx/xilinx_ml300.c
===================================================================
--- linux-2.6.20.orig/arch/ppc/platforms/4xx/xilinx_ml300.c
+++ linux-2.6.20/arch/ppc/platforms/4xx/xilinx_ml300.c
@@ -116,3 +116,20 @@ platform_init(unsigned long r3, unsigned
#endif
}
+static struct xilinxfb_platform_data xilinxfb_ml300_pdata = {
+ .rotate_screen = 1,
+ .screen_height_mm = 99,
+ .screen_width_mm = 132,
+};
+
+int __init virtex_device_fixup(struct platform_device *dev)
+{
+ if (strcmp(dev->name, "xilinxfb") == 0) {
+ if (dev->id != 0) /* paranoic */
+ return 1;
+ dev->dev.platform_data = &xilinxfb_ml300_pdata;
+ return 0;
+ }
+ return 0;
+}
+
Index: linux-2.6.20/arch/ppc/syslib/virtex_devices.c
===================================================================
--- linux-2.6.20.orig/arch/ppc/syslib/virtex_devices.c
+++ linux-2.6.20/arch/ppc/syslib/virtex_devices.c
@@ -71,7 +71,23 @@
}, \
}
+/*
+ * ML300/ML403 Video Device: shortcut macro for single instance
+ */
+#define XPAR_TFT(num) { \
+ .name = "xilinxfb", \
+ .id = num, \
+ .num_resources = 1, \
+ .resource = (struct resource[]) { \
+ { \
+ .start = XPAR_TFT_##num##_BASEADDR, \
+ .end = XPAR_TFT_##num##_BASEADDR+7, \
+ .flags = IORESOURCE_IO, \
+ }, \
+ }, \
+}
+
/* UART 8250 driver platform data table */
struct plat_serial8250_port virtex_serial_platform_data[] = {
#if defined(XPAR_UARTNS550_0_BASEADDR)
@@ -146,20 +162,12 @@ struct platform_device virtex_platform_d
XPAR_SYSACE(1),
#endif
- /* ML300/403 reference design framebuffer */
+ /* ML300/ML403 reference design framebuffer */
#if defined(XPAR_TFT_0_BASEADDR)
- {
- .name = "xilinxfb",
- .id = 0,
- .num_resources = 1,
- .resource = (struct resource[]) {
- {
- .start = XPAR_TFT_0_BASEADDR,
- .end = XPAR_TFT_0_BASEADDR+7,
- .flags = IORESOURCE_IO,
- },
- },
- },
+ XPAR_TFT(0),
+#endif
+#if defined(XPAR_TFT_1_BASEADDR)
+ XPAR_TFT(1),
#endif
};
next prev parent reply other threads:[~2007-05-03 17:24 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-03 17:26 [PATCH] Xilinx framebuffer device driver - 3d version Andrei Konovalov
2007-05-03 17:26 ` Andrei Konovalov
2007-05-03 17:29 ` Andrei Konovalov [this message]
2007-05-03 19:57 ` Antonino A. Daplas
2007-05-03 19:57 ` [Linux-fbdev-devel] " Antonino A. Daplas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=463A1BEC.4040700@ru.mvista.com \
--to=akonovalov@ru.mvista.com \
--cc=arnd@arndb.de \
--cc=linuxppc-embedded@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.