
Dear Himba,
in message 4112A5A7.8050609@siol.net you wrote:
- /* 7168 = 256*4*56/8 - actually 2 pages (8192 bytes) are allocated */
- params->u.videolfb.lfb_size = 7168;
...
- params->u.videolfb.lfb_size = 80896;
...
I speculated that it was just too small for any framebuffer out there nowadays, so I took liberty in increasing it.
You are wrong. There are 4 VFD's on the TRAB board, and this requires only 7 kB of framebuffer.
[I recommend to make the actual value configurable in the board's config file.]
Fine. That would introduce another CONFIG_xxx variable, right?
Right.
Or maybe we could provide FB driver with simple function that calculates the value upon configured LCD type and returns size on-the-fly instead of hardcoding it again somewhere...
That's fine with me, too. It just has to work :-)
This code looks like a 1:1 copy of the same function in "cpu/mpc8xx/lcd.c". Instead of duplicating the code, we should factor it out into a common source file.
It is from "cpu/mpc8xx/lcd.c". This could be put in common/ or drivers/ I presume - all common FB functions could be there. I haven't really compared the mpc8xx and pxa FB drivers in detail, but I think pxa FB is driven out of mpc8xx FB.
You are right. But with the other functions there was at least some minimal difference ;-)
OK, I'll try. Will put out RFC here in a while.
Thanks a lot!
Best regards,
Wolfgang Denk