Skip to contentSkip to conversation

video: SuperH Mobile LCDC Driver V2

PATCH In review Magnus Damm 5 participants 7 messages May 30, 2008 – Jun 2, 2008

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 video: SuperH Mobile LCDC Driver V2

This is the SuperH Mobile LCDC frame buffer driver V2, adding support for the LCDC block found in SuperH Mobile processors. The hardware supports up to two LCD panels per LCDC block, and both RGB and SYS interfaces can be used to hook up LCD panels/modules.

The device driver is a regular platform driver, so LCD configuration and board specific hooks are passed to the driver using platform data. LCD modules using SYS interface often require special configuration using the SYS bus, and to solve this cleanly the driver provides SYS interface operations to the board code.

Tested on sh7723 and sh7722 processors with a SYS16A QVGA panel and WVGA panels using RGB16 and RGB18 interfaces.

---

Changes since V1:
- updated license header
- improved polling code to use cpu_relax()
- introduced lcdc_wait_bit()
- added lcdc_chan_is_sublcd() function
- broke out start and stop code

 drivers/video/Kconfig            |   10 
 drivers/video/Makefile           |    2 
 drivers/video/sh_mobile_lcdcfb.c |  725 ++++++++++++++++++++++++++++++++++++++
 include/asm-sh/sh_mobile_lcdc.h  |   66 +++
 4 files changed, 803 insertions(+)
drivers/video/Kconfig +10 -0
@@ -1839,6 +1839,16 @@ config FB_W100
 
 	  If unsure, say N.
 
+config FB_SH_MOBILE_LCDC
+	tristate "SuperH Mobile LCDC framebuffer support"
+	depends on FB && SUPERH
+	select FB_CFB_FILLRECT
+	select FB_CFB_COPYAREA
+	select FB_CFB_IMAGEBLIT
+	default m
+	---help---
+	  Frame buffer driver for the on-chip SH-Mobile LCD controller.
+
 config FB_S3C2410
 	tristate "S3C2410 LCD framebuffer support"
 	depends on FB && ARCH_S3C2410
drivers/video/Makefile +2 -0
@@ -115,6 +115,8 @@ obj-$(CONFIG_FB_IBM_GXT4500)	  += gxt450
 obj-$(CONFIG_FB_PS3)		  += ps3fb.o
 obj-$(CONFIG_FB_SM501)            += sm501fb.o
 obj-$(CONFIG_FB_XILINX)           += xilinxfb.o
+obj-$(CONFIG_FB_SH_MOBILE_LCDC)	  += sh_mobile_lcdcfb.o
+obj-$(CONFIG_FB_SH7343VOU)	  += sh7343_voufb.o
 obj-$(CONFIG_FB_OMAP)             += omap/
 obj-$(CONFIG_XEN_FBDEV_FRONTEND)  += xen-fbfront.o
 
drivers/video/sh_mobile_lcdcfb.c new file +725 -0

725 lines not on this page · raw message

include/asm-sh/sh_mobile_lcdc.h new file +66 -0

66 lines not on this page · raw message

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

Acked-by on v1 1/1
#1 lore raw
Quoted 11 lines · On Fri, 30 May 2008 20:02:39 +0900 Magnus Damm <[email protected]> wrote:

This is the SuperH Mobile LCDC frame buffer driver V2, adding support for the LCDC block found in SuperH Mobile processors. The hardware supports up to two LCD panels per LCDC block, and both RGB and SYS interfaces can be used to hook up LCD panels/modules.

The device driver is a regular platform driver, so LCD configuration and board specific hooks are passed to the driver using platform data. LCD modules using SYS interface often require special configuration using the SYS bus, and to solve this cleanly the driver provides SYS interface operations to the board code.

Quoted 5 lines

Tested on sh7723 and sh7722 processors with a SYS16A QVGA panel and WVGA panels using RGB16 and RGB18 interfaces.

---

Does anybody know which tag is better for a reviewed patch:
"Acked-by" or "Reviewed-by" ?

Regards,
Krzysztof

----------------------------------------------------------------------
Tanie rozmowy!
Sprawdz >>> http://link.interia.pl/f1e13

#2 lore raw
Quoted 17 lines · On Fri, 30 May 2008 18:28:03 +0200 Krzysztof Helt <[email protected]>…
Quoted 14 lines · On Fri, 30 May 2008 20:02:39 +0900 Magnus Damm <[email protected]> wrote:

This is the SuperH Mobile LCDC frame buffer driver V2, adding support for the LCDC block found in SuperH Mobile processors. The hardware supports up to two LCD panels per LCDC block, and both RGB and SYS interfaces can be used to hook up LCD panels/modules.

The device driver is a regular platform driver, so LCD configuration and board specific hooks are passed to the driver using platform data. LCD modules using SYS interface often require special configuration using the SYS bus, and to solve this cleanly the driver provides SYS interface operations to the board code.

Tested on sh7723 and sh7722 processors with a SYS16A QVGA panel and WVGA panels using RGB16 and RGB18 interfaces.

Quoted 8 lines
Quoted 2 lines

---

Does anybody know which tag is better for a reviewed patch:
"Acked-by" or "Reviewed-by" ?

I consider Reviewed-by: to be much stronger that Acked-by:

You wouldn't believe some of the crap which has had cheerful Acked-by:s :(

Reviewed-by
#3 lore raw
Quoted 22 lines · On Fri, 30 May 2008 12:06:06 -0700 Andrew Morton <[email protected]>…
Quoted 20 lines · On Fri, 30 May 2008 18:28:03 +0200 Krzysztof Helt <[email protected]>…
Quoted 16 lines · On Fri, 30 May 2008 20:02:39 +0900 Magnus Damm <[email protected]> wrote:

This is the SuperH Mobile LCDC frame buffer driver V2, adding support for the LCDC block found in SuperH Mobile processors. The hardware supports up to two LCD panels per LCDC block, and both RGB and SYS interfaces can be used to hook up LCD panels/modules.

The device driver is a regular platform driver, so LCD configuration and board specific hooks are passed to the driver using platform data. LCD modules using SYS interface often require special configuration using the SYS bus, and to solve this cleanly the driver provides SYS interface operations to the board code.

Tested on sh7723 and sh7722 processors with a SYS16A QVGA panel and WVGA panels using RGB16 and RGB18 interfaces.

---

Quoted 8 lines
Quoted 5 lines

Does anybody know which tag is better for a reviewed patch:
"Acked-by" or "Reviewed-by" ?

I consider Reviewed-by: to be much stronger that Acked-by:

This driver has been really carefully checked.

Krzysztof

----------------------------------------------------------------------
Tanie rozmowy!
Sprawdz >>> http://link.interia.pl/f1e13

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

#4 lore raw

Which differences are bteween SuperH Mobile LCDC frame buffer and SH2A 7203 LCDC controller?

Thanks a lot.

Best regards

Alle 21:44, venerdì 30 maggio 2008, Krzysztof Helt ha scritto:

Quoted 4 lines

On Fri, 30 May 2008 12:06:06 -0700

Quoted 1 line · Andrew Morton

On Fri, 30 May 2008 18:28:03 +0200 Krzysztof Helt <[email protected]>

Quoted 41 lines · wrote:
Quoted 20 lines
Quoted 20 lines

On Fri, 30 May 2008 20:02:39 +0900

Quoted 16 lines · Magnus Damm

This is the SuperH Mobile LCDC frame buffer driver V2, adding support for the LCDC block found in SuperH Mobile processors. The hardware supports up to two LCD panels per LCDC block, and both RGB and SYS interfaces can be used to hook up LCD panels/modules.

The device driver is a regular platform driver, so LCD configuration and board specific hooks are passed to the driver using platform data. LCD modules using SYS interface often require special configuration using the SYS bus, and to solve this cleanly the driver provides SYS interface operations to the board code.

Tested on sh7723 and sh7722 processors with a SYS16A QVGA panel and WVGA panels using RGB16 and RGB18 interfaces.

---

Quoted 6 lines
Quoted 4 lines

Does anybody know which tag is better for a reviewed patch:
"Acked-by" or "Reviewed-by" ?

I consider Reviewed-by: to be much stronger that Acked-by:

This driver has been really carefully checked.

Krzysztof

----------------------------------------------------------------------
Tanie rozmowy!
Sprawdz >>> http://link.interia.pl/f1e13

--
To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Signature · 14 lines
Fabio Giovagnini

Aurion s.r.l.
via degli orti 11,
40050 Funo di Argelato (BO)
P.I e C.F.
00885711200
Tel. +39.335.8350919
Fax +39.051.8659009

www.aurion-tech.com

account telefono VoIP skype (www.skype.com):
aurion.giovagnini
#5 lore raw
Quoted 2 lines · Fabio Giovagnini

Which differences are bteween SuperH Mobile LCDC frame buffer and SH2A 7203 LCDC controller?

Judging from the data sheets the LCDC block in sh7203, sh7763 and sh7720 are identical. Except different base address for registers and palette. And maybe IRQ number and pin configuration. =) Anyway, the sh7760 LCDC is very similar but seems to be missing a few registers. I'm sure there are other parts that are using this LCDC block as well. Having a shared driver for sh7203/sh7763/sh7720 and sh7760 makes sense.

The SuperH Mobile LCDC block (sh7723/sh7722/sh7343) is very different:
Supported pixel formats, hardware interfaces, number of channels, register layout and register width.

/ magnus

Acked-by
#6 lore raw
In reply to Andrew Morton
Quoted 24 lines · Andrew Morton
Quoted 22 lines · On Fri, 30 May 2008 18:28:03 +0200 Krzysztof Helt <[email protected]>…
Quoted 11 lines · On Fri, 30 May 2008 20:02:39 +0900 Magnus Damm <[email protected]> wrote:

This is the SuperH Mobile LCDC frame buffer driver V2, adding support for the LCDC block found in SuperH Mobile processors. The hardware supports up to two LCD panels per LCDC block, and both RGB and SYS interfaces can be used to hook up LCD panels/modules.

The device driver is a regular platform driver, so LCD configuration and board specific hooks are passed to the driver using platform data. LCD modules using SYS interface often require special configuration using the SYS bus, and to solve this cleanly the driver provides SYS interface operations to the board code.

Quoted 5 lines

Tested on sh7723 and sh7722 processors with a SYS16A QVGA panel and WVGA panels using RGB16 and RGB18 interfaces.

---

Quoted 7 lines
Quoted 3 lines

Does anybody know which tag is better for a reviewed patch:
"Acked-by" or "Reviewed-by" ?

I consider Reviewed-by: to be much stronger that Acked-by:

You wouldn't believe some of the crap which has had cheerful Acked-by:s :(

In that case:

:-)