mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 17:23:56 -06:00
msi/msix: added API to set MSI message address and data
Added (msi|msix)_set_message() function for whoever might want to use them. Currently msi_notify()/msix_notify() write to these vectors to signal the guest about an interrupt so the correct values have to written there by the guest or QEMU. For example, POWER guest never initializes MSI/MSIX vectors, instead it uses RTAS hypercalls. So in order to support MSIX for virtio-pci on POWER we have to initialize MSI/MSIX message from QEMU. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
0ae1625177
commit
932d4a42af
4 changed files with 32 additions and 0 deletions
1
hw/msi.h
1
hw/msi.h
|
@ -31,6 +31,7 @@ struct MSIMessage {
|
|||
|
||||
extern bool msi_supported;
|
||||
|
||||
void msi_set_message(PCIDevice *dev, MSIMessage msg);
|
||||
bool msi_enabled(const PCIDevice *dev);
|
||||
int msi_init(struct PCIDevice *dev, uint8_t offset,
|
||||
unsigned int nr_vectors, bool msi64bit, bool msi_per_vector_mask);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue