Re: [PATCH kvm-unit-tests 2/4] Introduce a C++ wrapper for the kvm APIs

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

 



On 11/24/2010 07:02 PM, Gleb Natapov wrote:
On Wed, Nov 24, 2010 at 06:56:52PM +0200, Avi Kivity wrote:
>  On 11/24/2010 06:52 PM, Gleb Natapov wrote:
>  >>   Plus some magic glue.  You can't say it is an ISA bridge.  It's
>  >>   exactly what its spec says it is.
>  >>
>  >First thing my spec says is "Bridge Between the PCI Bus and ISA Bus"
>
>  It's the first item in a list of features.  Be serious.
>
I am serious. The fact that it provides IDE or kbd doesn't make this IDE
or kbd special. It means that it has gates that provide functionality of
those chips. Just like SoC really. IDE doesn't become part of ARM cpu
just because some SoC somewhere include them on the same silicon.

They aren't special.  They're just part of the PIIX3 device.

>  When we do have a spec for something, we should implement it as the
>  spec says, not according to our ideas of how it should be.
>
PIIX3 is composite device. It is not one device. To emulate it you need
to provide functionality of all devices included om PIIX3. Spec says
nothing about how it should be implemented.

Right, we could (and probably should) implement it as

  class PIIX3 {
  private:
      class isa_bridge { .... };
      isa_bridge isa_bridge;
      i8042 kbc;
      ...
  }

So the thing becomes just a glue layer for various components. But when pc.c says PIIX3, it gets what the spec says, not something else.

--
error compiling committee.c: too many arguments to function

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux