mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-12-17 21:26:13 -07:00
libqos: allow qpci_iomap to return BAR mapping size
This patch allows qpci_iomap to return the size of the BAR mapping that it created, to allow driver applications (e.g, ahci-test) to make determinations about the suitability or the mapping size, or in the specific case of AHCI, how many ports are supported by the HBA. Signed-off-by: John Snow <jsnow@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
7f2a5ae6c1
commit
6ce7100e7f
5 changed files with 10 additions and 7 deletions
|
|
@ -138,9 +138,9 @@ void qpci_io_writel(QPCIDevice *dev, void *data, uint32_t value)
|
|||
dev->bus->io_writel(dev->bus, data, value);
|
||||
}
|
||||
|
||||
void *qpci_iomap(QPCIDevice *dev, int barno)
|
||||
void *qpci_iomap(QPCIDevice *dev, int barno, uint64_t *sizeptr)
|
||||
{
|
||||
return dev->bus->iomap(dev->bus, dev, barno);
|
||||
return dev->bus->iomap(dev->bus, dev, barno, sizeptr);
|
||||
}
|
||||
|
||||
void qpci_iounmap(QPCIDevice *dev, void *data)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue