diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2011-05-05 13:05:32 -0500 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2011-05-05 13:05:32 -0500 |
commit | 3964f535c35c08470ac69bd553282af500bc8bb0 (patch) | |
tree | ba83992b5bcfda451371174ce3e8be1496c70c73 /hw/ide | |
parent | a69fb35079f682f99dd4d077b76232763d832d42 (diff) | |
parent | 5300f1a5487f67f0bde8ee1081b799108668cb1d (diff) |
Merge remote-tracking branch 'mst/for_anthony' into staging
Diffstat (limited to 'hw/ide')
-rw-r--r-- | hw/ide/ahci.c | 9 | ||||
-rw-r--r-- | hw/ide/ahci.h | 3 | ||||
-rw-r--r-- | hw/ide/ich.c | 8 |
3 files changed, 2 insertions, 18 deletions
diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c index 98bdf7059a..c6e0c7767e 100644 --- a/hw/ide/ahci.c +++ b/hw/ide/ahci.c @@ -1129,15 +1129,6 @@ void ahci_uninit(AHCIState *s) qemu_free(s->dev); } -void ahci_pci_map(PCIDevice *pci_dev, int region_num, - pcibus_t addr, pcibus_t size, int type) -{ - struct AHCIPCIState *d = (struct AHCIPCIState *)pci_dev; - AHCIState *s = &d->ahci; - - cpu_register_physical_memory(addr, size, s->mem); -} - void ahci_reset(void *opaque) { struct AHCIPCIState *d = opaque; diff --git a/hw/ide/ahci.h b/hw/ide/ahci.h index a4560c41b6..dc86951ebf 100644 --- a/hw/ide/ahci.h +++ b/hw/ide/ahci.h @@ -325,9 +325,6 @@ typedef struct NCQFrame { void ahci_init(AHCIState *s, DeviceState *qdev, int ports); void ahci_uninit(AHCIState *s); -void ahci_pci_map(PCIDevice *pci_dev, int region_num, - pcibus_t addr, pcibus_t size, int type); - void ahci_reset(void *opaque); #endif /* HW_IDE_AHCI_H */ diff --git a/hw/ide/ich.c b/hw/ide/ich.c index a3d475c59a..e44339b078 100644 --- a/hw/ide/ich.c +++ b/hw/ide/ich.c @@ -94,8 +94,7 @@ static int pci_ich9_ahci_init(PCIDevice *dev) qemu_register_reset(ahci_reset, d); /* XXX BAR size should be 1k, but that breaks, so bump it to 4k for now */ - pci_register_bar(&d->card, 5, 0x1000, PCI_BASE_ADDRESS_SPACE_MEMORY, - ahci_pci_map); + pci_register_bar_simple(&d->card, 5, 0x1000, 0, d->ahci.mem); msi_init(dev, 0x50, 1, true, false); @@ -110,10 +109,7 @@ static int pci_ich9_uninit(PCIDevice *dev) struct AHCIPCIState *d; d = DO_UPCAST(struct AHCIPCIState, card, dev); - if (msi_enabled(dev)) { - msi_uninit(dev); - } - + msi_uninit(dev); qemu_unregister_reset(ahci_reset, d); ahci_uninit(&d->ahci); |