[U-Boot-Users] [PATCH] LOGO: Adds LCD color map 565 support.

Wolfgang Grandegger
2007-05-30T12:28:06Z

Hi Rodolfo,

some more comments.

Rodolfo Giometti wrote:
> On Wed, May 30, 2007 at 09:50:55AM +0200, Wolfgang Grandegger wrote:
>> Hi Rodolfo,
>>
>> sorry for the late answer.
>
> Don't worry about it I'm a little busy too. :)
>
>> One limitation of bitmap_plot, and also display_bitmap is, that it does
>> not work for back&white displays, even if the latter function is used
>> somehow for black&white display, e.g. with ugly hacks for MCC200. I
>> would like to have generic drawing functions for 1, 8 and 16 bpp.
>
> My suggestion is to remove completely the logo support and rewrite the
> function:
>
> int lcd_display_bitmap(ulong bmp_image, int x, int y)
>
> in order to support, in a easy configurable way, all bpp LCD
> resolutions.
>
> On my side I can write and test the code for 16bpp LCD on a PXA2xx but
> I need help and support for other resolutions and CPUs! It could be
> acceptable to write a first version of such function for my hardware
> and then adding the other support even if it could break current board
> logo/splash support?

Well, LCD support is broken partly for various boards anyhow. Actually
it's peppered with hacks and errors :-(. Here some examples:

- lcd_display_bitmap() does not work for black&white.

- lcd_setcolreg() is wrong for MPC823 and PXA. The color arguments are 8
bit values (0..ff) and must be converted properly for the color table
of the device. e.g the MPC823 has only 16 values per color.

- #ifdef mess.

- The common code should be hardware _independent_.

- CFG_INVERT_COLORS should be removed like in the Linux driver.

I also have just a MPC823 with various panels for testing but we should
at least fix the obvious things. I'm currently working on various
issues, especially to support dynamic LCD controller configuration in
U-Boot, requiring substantial modifications anyhow. Nevertheless, I'm
not willing to spend too much time on this driver, because it's for old
hardware. It's not interesting for new projects.

Wolfgang.