[SeaBIOS] [PATCH 3/3] bochsvga: dynamic generation of EDID

Hiroshi Miura miurahr at linux.com
Tue Sep 11 01:35:34 CEST 2012


Hi,

On 2012.09.10 15:57, Gerd Hoffmann wrote:
> On 09/09/12 16:00, Hiroshi Miura wrote:
>> Generate EDID according to preferred resolution
>> from VBE_DISPI interface.
>> +void bochs_init_preferred_resolution(u16 max_xres, u16 max_yres) {
>> +
>> +    if (max_xres >= 1920 && max_yres >= 1200){
>> +        max_xres = 1920; max_yres = 1200;
>> +    } else if (max_xres >= 1600 && max_yres >= 1200){
>> +        max_xres = 1600; max_yres = 1200;
>> +    } else if (max_xres >= 1280 && max_yres >= 1024){
>> +        max_xres = 1280; max_yres = 1024;
>> +    } else {
>> +        max_xres = 1152; max_yres = 864;
>> +    }
>> +    SET_VGA(prefered_xres,max_xres);
>> +    SET_VGA(prefered_yres,max_yres);
>> +}
>>      u16 max_xres = dispi_read(VBE_DISPI_INDEX_XRES);
>> +    u16 max_yres = dispi_read(VBE_DISPI_INDEX_YRES);
>> +    bochs_init_preferred_resolution(max_xres, max_yres);
> So how this is supposed to work?  qemu gives you fixed max_xres and
> max_yres values, you'll never see anything below 1600x1200 ...
>

After implementing this in Seabios/vgabios, qemu have a
option to provide a preferred resolution (from several alternatives) thru API.

I'd like to propose qemu to implement max_xres/max_yres generating
from user configuration and/or real-display resolutions.

It looks chicken-egg thing, which one should implement first?
I think vgabios is good for implement first and qemu next.

I know there was discussion adding API interface to provide edid data block
from qemu. and qemu can handle such as /etc/qemu-fw/some-binary.bin
for configuration.

This is alternative proposal for not-changing bochs API and help
qemu to select resolution in easy way.

Hiroshi






More information about the SeaBIOS mailing list