Revision 4cff0a59 hw/pci.c
b/hw/pci.c | ||
---|---|---|
1558 | 1558 |
pci_add_option_rom(pci_dev); |
1559 | 1559 |
|
1560 | 1560 |
if (bus->hotplug) { |
1561 |
/* lower layer must check qdev->hotplugged */ |
|
1562 |
rc = bus->hotplug(bus->hotplug_qdev, pci_dev, 1); |
|
1561 |
/* Let buses differentiate between hotplug and when device is |
|
1562 |
* enabled during qemu machine creation. */ |
|
1563 |
rc = bus->hotplug(bus->hotplug_qdev, pci_dev, |
|
1564 |
qdev->hotplugged ? PCI_HOTPLUG_ENABLED: |
|
1565 |
PCI_COLDPLUG_ENABLED); |
|
1563 | 1566 |
if (rc != 0) { |
1564 | 1567 |
int r = pci_unregister_device(&pci_dev->qdev); |
1565 | 1568 |
assert(!r); |
... | ... | |
1573 | 1576 |
{ |
1574 | 1577 |
PCIDevice *dev = DO_UPCAST(PCIDevice, qdev, qdev); |
1575 | 1578 |
|
1576 |
return dev->bus->hotplug(dev->bus->hotplug_qdev, dev, 0); |
|
1579 |
return dev->bus->hotplug(dev->bus->hotplug_qdev, dev, |
|
1580 |
PCI_HOTPLUG_DISABLED); |
|
1577 | 1581 |
} |
1578 | 1582 |
|
1579 | 1583 |
void pci_qdev_register(PCIDeviceInfo *info) |
Also available in: Unified diff