]> git.proxmox.com Git - mirror_qemu.git/commit
hw/display: add new bochs-display device
authorGerd Hoffmann <kraxel@redhat.com>
Tue, 22 May 2018 16:50:55 +0000 (18:50 +0200)
committerGerd Hoffmann <kraxel@redhat.com>
Thu, 24 May 2018 08:42:13 +0000 (10:42 +0200)
commit765c94290863eef1fc4a67819d452cc13b7854a1
tree6b12e1aa0050dd87b160867b8393fa532ddbe1c1
parent83ff909f93d35368832230c1a4e70c84793a695c
hw/display: add new bochs-display device

After writing up the virtual mdev device emulating a display supporting
the bochs vbe dispi interface (mbochs.ko) and seeing how simple it
actually is I've figured that would be useful for qemu too.

So, here it is, -device bochs-display.  It is basically -device VGA
without legacy vga emulation.  PCI bar 0 is the framebuffer, PCI bar 2
is mmio with the registers.  The vga registers are simply not there
though, neither in the legacy ioport location nor in the mmio bar.
Consequently it is PCI class DISPLAY_OTHER not DISPLAY_VGA.

So there is no text mode emulation, no weird video modes (planar,
256color palette), no memory window at 0xa0000.  Just a linear
framebuffer in the pci memory bar.  And the amount of code to emulate
this (and therefore the attack surface) is an order of magnitude smaller
when compared to vga emulation.

Compatibility wise it works with OVMF (latest git master).
The bochs-drm.ko linux kernel module can handle it just fine too.
So UEFI guests should not see any functional difference to VGA.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Tested-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-id: 20180522165058.15404-4-kraxel@redhat.com
hw/display/Makefile.objs
hw/display/bochs-display.c [new file with mode: 0644]