On Tue, 2012-08-07 at 07:30 +0200, Gerd Hoffmann wrote: > On 08/06/12 23:16, Benjamin Herrenschmidt wrote: > > On Mon, 2012-08-06 at 15:20 +0200, Gerd Hoffmann wrote: > >> There are discussions about re-doing the guest/host interface (command > >> rings etc) now and then, by adding a qxl2 device (or maybe even extend > >> stdvga), dropping a bunch of backward compatibility stuff in qxl.c. > >> > >> Sending the spice commands over virtio is certainly an option here. > >> I'm > >> not sure it is possible to drive virtio rings from userspace (Xorg > >> driver), but that issue should go away with the qxl kms driver in the > >> works. > > > > Anything that gets rid of the qxl memory region API is welcome ;-) Some > > of that stuff is really gross. > > Well, it is needed for sanity checking memory references (to images etc) > in qxl commands, so we can't just zap it. But having a kms driver in > kernel space makes things easier again: You could simply register a > single memory region for the guest ram, then basically use guest > physical addresses for qxl memory references. qxl commands & data can > live in guest ram and you can stick references to the commands into > virtio rings ...
Or you use a sane model in the first place that hides memory references behind object IDs :-) Yes, going via a KMS driver will go a long way toward fixing some of that. I would still like to experiment a bit if time permits with a different model which is basically GL paravirt via a virtio channel on top of virtio-vga (possibly limited to GL/ES at least initially). Guest side, we'd then have a simple DRM and use Glamor to turn all 2D rendering into GL. Cheers, Ben.