Device Modelling

Requirements

While it is sometimes necessary to implement PCI bridges (e.g. GRPCI2), the more common task is to implement PCI devices.

A PCI device in TEMU must support the following interfaces:

  • PCIDevIface implementing the PCI device interface. Used for for accessing config info about the PCI device.

  • MemAccessIface[6] implementing the PCI memory access functions for each BAR.

  • ExpROMAccessIface implementing accesses to PCI expansion ROM.

  • ConfigAccessIface implementing the memory access interface for the configuration space.

That means that MemAccessIface may be either IO or PCI mem. This depends on the hard coded value in the bar.