mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 01:33:56 -06:00
hw/riscv/virt: Add the BDF of IOMMU to RISCVVirtState structure
When the IOMMU is implemented as a PCI device, its BDF is created locally in virt.c. However, the same BDF is also required in virt-acpi-build.c to support ACPI. Therefore, make this information part of the global RISCVVirtState structure so that it can be accessed outside of virt.c as well. Signed-off-by: Sunil V L <sunilvl@ventanamicro.com> Reviewed-by: Daniel Henrique Barboza <dbarboza@ventanamicro.com> Message-ID: <20250322043139.2003479-2-sunilvl@ventanamicro.com> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
parent
757a34115e
commit
d2a88aca76
2 changed files with 2 additions and 0 deletions
|
@ -1117,6 +1117,7 @@ static void create_fdt_iommu(RISCVVirtState *s, uint16_t bdf)
|
|||
qemu_fdt_setprop_cells(fdt, pci_node, "iommu-map",
|
||||
0, iommu_phandle, 0, bdf,
|
||||
bdf + 1, iommu_phandle, bdf + 1, 0xffff - bdf);
|
||||
s->pci_iommu_bdf = bdf;
|
||||
}
|
||||
|
||||
static void finalize_fdt(RISCVVirtState *s)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue