mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
msi: implements msi
implements msi related functions. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
99443c21b0
commit
e4c7d2aef8
4 changed files with 401 additions and 4 deletions
10
hw/pci.h
10
hw/pci.h
|
@ -109,11 +109,12 @@ typedef struct PCIIORegion {
|
|||
|
||||
/* Bits in cap_present field. */
|
||||
enum {
|
||||
QEMU_PCI_CAP_MSIX = 0x1,
|
||||
QEMU_PCI_CAP_EXPRESS = 0x2,
|
||||
QEMU_PCI_CAP_MSI = 0x1,
|
||||
QEMU_PCI_CAP_MSIX = 0x2,
|
||||
QEMU_PCI_CAP_EXPRESS = 0x4,
|
||||
|
||||
/* multifunction capable device */
|
||||
#define QEMU_PCI_CAP_MULTIFUNCTION_BITNR 2
|
||||
#define QEMU_PCI_CAP_MULTIFUNCTION_BITNR 3
|
||||
QEMU_PCI_CAP_MULTIFUNCTION = (1 << QEMU_PCI_CAP_MULTIFUNCTION_BITNR),
|
||||
};
|
||||
|
||||
|
@ -171,6 +172,9 @@ struct PCIDevice {
|
|||
/* Version id needed for VMState */
|
||||
int32_t version_id;
|
||||
|
||||
/* Offset of MSI capability in config space */
|
||||
uint8_t msi_cap;
|
||||
|
||||
/* Location of option rom */
|
||||
char *romfile;
|
||||
ram_addr_t rom_offset;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue