qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 1 of 2] [UPDATE] DisplayState interface change


From: Stefano Stabellini
Subject: Re: [Qemu-devel] [PATCH 1 of 2] [UPDATE] DisplayState interface change
Date: Fri, 21 Nov 2008 11:31:17 +0000
User-agent: Thunderbird 2.0.0.14 (X11/20080505)

Paul Brook wrote:

>> If the backend is smart enought to share the buffer it does so checking
>> that it is the current active console first (look at
>> hw/vga.c:vga_draw_graphic, vga.c is the only "smart" backend at the
>> moment).
> 
> This worries me. We shouldn't have "smart" and dumb devices, they should all 
> just work. This suggests you've either got the abstraction wrong, or only 
> implemented half of the required changes.
> 
> It feels like you're replacing one bit of host knowledge with another. IMHO 
> We 
> should be aiming for individual devices to know less about how the host 
> displays the image.
> 


All the backends work, but if a backend wants to reuse a preexisting
buffer it needs to check that its QEMUConsole is the active console.
This is not knowledge of the host, it is knowledge of the fact that my
QEMUConsole could not be active at the moment.
I could easily add a qemu_resizeDisplaySurfaceFrom that takes a pointer
to a buffer but I thought that it was uglier, maybe I am wrong.


> Ok. In that case we should be removing QEMUConsole and giving every
output
> source[*] its own DisplayState.
>
> [*] output source == Emulated device or virtual console.
>

Even though this model you are proposing is simpler, it has the
disadvantage that implies a display buffer per backend while at the
moment we are sharing it between multiple backends.

In any case, I can assure you that the change you want to make does
*not* go against my patches, they are orthogonal, they neither help nor
cause problems to each other, so I would suggest to examine them separately.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]