[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH V6 for-2.3 21/26] hw/pci: inform bios if the system
From: |
Marcel Apfelbaum |
Subject: |
[Qemu-devel] [PATCH V6 for-2.3 21/26] hw/pci: inform bios if the system has extra pci root buses |
Date: |
Thu, 19 Mar 2015 20:52:56 +0200 |
From: Marcel Apfelbaum <address@hidden>
The bios looks for 'etc/extra-pci-roots' to decide if
is going to scan further buses after bus 0 tree.
Signed-off-by: Marcel Apfelbaum <address@hidden>
---
hw/i386/pc.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/hw/i386/pc.c b/hw/i386/pc.c
index 79eaad5..7a8c6dd 100644
--- a/hw/i386/pc.c
+++ b/hw/i386/pc.c
@@ -1076,6 +1076,19 @@ void pc_guest_info_machine_done(Notifier *notifier, void
*data)
PcGuestInfoState *guest_info_state = container_of(notifier,
PcGuestInfoState,
machine_done);
+ PCIHostState *snooped_host = find_i440fx();
+ PCIHostBridgeSnoopedClass *snooped_class =
+ PCI_HOST_BRIDGE_SNOOPED_GET_CLASS(snooped_host);
+ GPtrArray *snooping_hosts = snooped_class->snooping_hosts(snooped_host);
+ int extra_hosts = snooping_hosts->len;
+
+ if (extra_hosts && guest_info_state->info.fw_cfg) {
+ uint64_t *val = g_malloc(sizeof(*val));
+ *val = cpu_to_le64(extra_hosts);
+ fw_cfg_add_file(guest_info_state->info.fw_cfg,
+ "etc/extra-pci-roots", val, sizeof(*val));
+ }
+
acpi_setup(&guest_info_state->info);
}
--
2.1.0
- [Qemu-devel] [PATCH V6 for-2.3 08/26] acpi: add aml_while() term, (continued)
- [Qemu-devel] [PATCH V6 for-2.3 08/26] acpi: add aml_while() term, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 13/26] hw/pci-host: introduce TYPE_PCI_HOST_BRIDGE_SNOOPED interface, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 14/26] hw/pci-host/piix: implement TYPE_PCI_HOST_BRIDGE_SNOOPED interface, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 10/26] hw/pci: made pci_bus_is_root a PCIBusClass method, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 11/26] hw/pci: made pci_bus_num a PCIBusClass method, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 16/26] hw/apci: add _PRT method for extra PCI root busses, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 15/26] hw/acpi: add support for i440fx 'snooping' root busses, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 12/26] hw/pci: introduce TYPE_PCI_MAIN_HOST_BRIDGE interface, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 17/26] hw/acpi: add _CRS method for extra root busses, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 19/26] hw/pci: removed 'rootbus nr is 0' assumption from qmp_pci_query, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 21/26] hw/pci: inform bios if the system has extra pci root buses,
Marcel Apfelbaum <=
- [Qemu-devel] [PATCH V6 for-2.3 18/26] hw/acpi: remove from root bus 0 the crs resources used by other busses., Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 25/26] apci: fix PXB behaviour if used with unsupported BIOS, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 22/26] hw/pxb: add map_irq func, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 20/26] hw/pci: introduce PCI Expander Bridge (PXB), Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 24/26] hw/pxb: add numa_node parameter, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 26/26] docs: Add PXB documentation, Marcel Apfelbaum, 2015/03/19
- [Qemu-devel] [PATCH V6 for-2.3 23/26] hw/pci_bus: add support for NUMA nodes, Marcel Apfelbaum, 2015/03/19
- Re: [Qemu-devel] [PATCH V6 for-2.3 00/26] hw/pc: implement multiple primary busses for pc machines, Paolo Bonzini, 2015/03/19