[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFT PATCH v1 29/30] pci-host/*: substitute ->qdev casts wi
From: |
peter . crosthwaite |
Subject: |
[Qemu-devel] [RFT PATCH v1 29/30] pci-host/*: substitute ->qdev casts with DEVICE() |
Date: |
Tue, 11 Jun 2013 17:01:56 +1000 |
From: Peter Crosthwaite <address@hidden>
Signed-off-by: Peter Crosthwaite <address@hidden>
---
hw/pci-bridge/dec.c | 2 +-
hw/pci-host/apb.c | 4 ++--
hw/pci-host/q35.c | 4 ++--
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/pci-bridge/dec.c b/hw/pci-bridge/dec.c
index cff458b..1e5611d 100644
--- a/hw/pci-bridge/dec.c
+++ b/hw/pci-bridge/dec.c
@@ -88,7 +88,7 @@ PCIBus *pci_dec_21154_init(PCIBus *parent_bus, int devfn)
"dec-21154-p2p-bridge");
br = DO_UPCAST(PCIBridge, dev, dev);
pci_bridge_map_irq(br, "DEC 21154 PCI-PCI bridge", dec_map_irq);
- qdev_init_nofail(&dev->qdev);
+ qdev_init_nofail(DEVICE(dev));
return pci_bridge_get_sec_bus(br);
}
diff --git a/hw/pci-host/apb.c b/hw/pci-host/apb.c
index e099655..f3987ff 100644
--- a/hw/pci-host/apb.c
+++ b/hw/pci-host/apb.c
@@ -467,7 +467,7 @@ PCIBus *pci_apb_init(hwaddr special_base,
br = DO_UPCAST(PCIBridge, dev, pci_dev);
pci_bridge_map_irq(br, "Advanced PCI Bus secondary bridge 1",
pci_apb_map_irq);
- qdev_init_nofail(&pci_dev->qdev);
+ qdev_init_nofail(DEVICE(dev));
*bus2 = pci_bridge_get_sec_bus(br);
pci_dev = pci_create_multifunction(d->bus, PCI_DEVFN(1, 1), true,
@@ -475,7 +475,7 @@ PCIBus *pci_apb_init(hwaddr special_base,
br = DO_UPCAST(PCIBridge, dev, pci_dev);
pci_bridge_map_irq(br, "Advanced PCI Bus secondary bridge 2",
pci_apb_map_irq);
- qdev_init_nofail(&pci_dev->qdev);
+ qdev_init_nofail(DEVICE(pci_dev));
*bus3 = pci_bridge_get_sec_bus(br);
return d->bus;
diff --git a/hw/pci-host/q35.c b/hw/pci-host/q35.c
index 24df6b5..d04471c 100644
--- a/hw/pci-host/q35.c
+++ b/hw/pci-host/q35.c
@@ -104,8 +104,8 @@ static const TypeInfo q35_host_info = {
/* PCIe MMCFG */
static void mch_update_pciexbar(MCHPCIState *mch)
{
- PCIDevice *pci_dev = &mch->d;
- BusState *bus = qdev_get_parent_bus(&pci_dev->qdev);
+ PCIDevice *pci_dev = PCI_DEVICE(mch);
+ BusState *bus = qdev_get_parent_bus(DEVICE(pci_dev));
DeviceState *qdev = bus->parent;
Q35PCIHost *s = Q35_HOST_DEVICE(qdev);
--
1.8.3.rc1.44.gb387c77.dirty
- [Qemu-devel] [RFT PATCH v1 19/30] pci-bridge/*: substitute ->qdev casts with DEVICE(), (continued)
- [Qemu-devel] [RFT PATCH v1 19/30] pci-bridge/*: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 20/30] misc/vfio: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 21/30] net/eepro100: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 22/30] net/ne2000: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 23/30] usb/*: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 24/30] watchdog/wdt_i6300esb: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 25/30] scsi/vmw_pvscsi: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 26/30] i2c/smbus_ich9: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 27/30] ide/cmd646: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 28/30] ide/via: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11
- [Qemu-devel] [RFT PATCH v1 29/30] pci-host/*: substitute ->qdev casts with DEVICE(),
peter . crosthwaite <=
- [Qemu-devel] [RFT PATCH v1 30/30] i386/*: substitute ->qdev casts with DEVICE(), peter . crosthwaite, 2013/06/11