mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
pc: add acpi-device link to PCMachineState
the link will used later to access device implementing ACPI functions instead of adhoc lookup in QOM tree. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Acked-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
f816a62daa
commit
781bbd6bec
5 changed files with 34 additions and 4 deletions
|
@ -483,13 +483,17 @@ Object *piix4_pm_find(void)
|
|||
|
||||
I2CBus *piix4_pm_init(PCIBus *bus, int devfn, uint32_t smb_io_base,
|
||||
qemu_irq sci_irq, qemu_irq smi_irq,
|
||||
int kvm_enabled, FWCfgState *fw_cfg)
|
||||
int kvm_enabled, FWCfgState *fw_cfg,
|
||||
DeviceState **piix4_pm)
|
||||
{
|
||||
DeviceState *dev;
|
||||
PIIX4PMState *s;
|
||||
|
||||
dev = DEVICE(pci_create(bus, devfn, TYPE_PIIX4_PM));
|
||||
qdev_prop_set_uint32(dev, "smb_io_base", smb_io_base);
|
||||
if (piix4_pm) {
|
||||
*piix4_pm = dev;
|
||||
}
|
||||
|
||||
s = PIIX4_PM(dev);
|
||||
s->irq = sci_irq;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue