qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 0/4] vga: new display devices


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] [PATCH 0/4] vga: new display devices
Date: Thu, 13 Mar 2014 09:22:40 +0100

>     +---------->IS_PCI_VGA (Pci):
>     |             "Found PCI VGA device"

> > +    k->class_id = PCI_CLASS_DISPLAY_OTHER;
> 
> and from qemu's "include/hw/pci/pci_ids.h":
> 
> > #define PCI_CLASS_DISPLAY_VGA            0x0300
> > #define PCI_CLASS_DISPLAY_OTHER          0x0380
> 
> I think this is the cause of the mismatch.

Yes, it is.  First byte (0x03) of the class says what it is, second byte
of class (0x00 / 0x80) specifies the programming interface.

So, it is a display adapter, but it isn't vga compatible, therefore
specifying PCI_CLASS_DISPLAY_VGA would be asking for trouble as trying
to program it using the standard vga io ports isn't going to work ...

[ same picture with virtio-gpu btw:  The variant with the vga compat
  bits declares itself as PCI_CLASS_DISPLAY_VGA whereas the variant
  without is PCI_CLASS_DISPLAY_OTHER ]

> Does the following OVMF patch help?
> 
> > -  if (IS_PCI_VGA (Pci)) {
> > +  if (IS_PCI_DISPLAY (Pci)) {

Yes.

thanks,
  Gerd





reply via email to

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