
Dear Stefano Babic,
In message 4CCFDEBA.2070203@denx.de you wrote:
We could introduce a weak function, that a board maintainer can decide to implement or not. This maintains the compatibility with the most drivers where vpanel is static initialized.
In which way is this board dependent?
Because each board uses a different LCD with a different resolution, and this requires a different amount of memory. This is not different as we see in Linux, because the framebuffer properties are set in the board file before to be passed to the framebuffer driver.
Well, if _that_ was what we are using, the memory requirements were fixed, and we could use compile-time constants.
But what you discussed before was the option to _switch_ resolutions, so there has to be a way to select the cosen resolution (in an environment variable?), and then this setting is used for the memory calculations.
And then the calculation depends only on the current setting - which is _not_ board dependent.
Boards would start with a (board dependent) default setting, though.
Best regards,
Wolfgang Denk