hw/arm/virt: Add virtio-mmio-transports property
PATCH v2 1/1 hw/arm/virt: Add virtio-mmio-transports property
Windows ARM64 guests detect virtio-mmio devices declared in ACPI tables even when no backend is attached. This causes "Unknown devices" (ACPI\LNRO0005) to appear in Device Manager.
Until Windows fixes that by supporting, add a new machine property 'virtio-mmio-transports' to control the number of virtio-mmio transports instantiated. The default remains NUM_VIRTIO_TRANSPORTS (32) for backward compatibility. Setting it to 0 allows users to disable virtio-mmio entirely.
Usage: -machine virt,virtio-mmio-transports=0
---
Changes in v2:
- Renamed property from virtio-transports to virtio-mmio-transports
- Added documentation in docs/system/arm/virt.rst
docs/system/arm/virt.rst | 5 +++++ hw/arm/virt-acpi-build.c | 2 +- hw/arm/virt.c | 43 ++++++++++++++++++++++++++++++++++++++-- include/hw/arm/virt.h | 1 + 4 files changed, 48 insertions(+), 3 deletions(-)
docs/system/arm/virt.rst +5 -0
@@ -212,6 +212,11 @@ dtb-randomness dtb-kaslr-seed A deprecated synonym for dtb-randomness. +virtio-mmio-transports + Set the number of virtio-mmio transports to create (between 0 and 32; + the default is 32). Unused transports are harmless, but you can + use this property to avoid exposing them to the guest if you wish. + x-oem-id Set string (up to 6 bytes) to override the default value of field OEMID in ACPI table header.
hw/arm/virt-acpi-build.c +1 -1
@@ -1150,7 +1150,7 @@ build_dsdt(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms)fw_cfg_acpi_dsdt_add (scope, &memmap[VIRT_FW_CFG ]);virtio_acpi_dsdt_add (scope, memmap[VIRT_MMIO ].base, memmap[VIRT_MMIO ].size, (irqmap[VIRT_MMIO ] +ARM_SPI_BASE ), -0 ,NUM_VIRTIO_TRANSPORTS ); +0 , vms->virtio_transports);acpi_dsdt_add_pci (scope, memmap, irqmap[VIRT_PCIE ] +ARM_SPI_BASE , vms);if (vms->acpi_dev) { build_ged_aml(scope, "\\_SB."GED_DEVICE,
hw/arm/virt.c +41 -2
73 lines not on this page · raw message
include/hw/arm/virt.h +1 -0
@@ -169,6 +169,7 @@ struct VirtMachineState {uint32_t msi_phandle;uint32_t iommu_phandle;int psci_conduit; +uint8_t virtio_transports;hwaddr highest_gpa;DeviceState *gic;DeviceState *acpi_dev;
Signature · 1 line
2.53.0
Peter Maydell
AppliedQuoted 11 lines · Mohammadfaiz Bawa
Windows ARM64 guests detect virtio-mmio devices declared in ACPI tables even when no backend is attached. This causes "Unknown devices" (ACPI\LNRO0005) to appear in Device Manager.
Until Windows fixes that by supporting, add a new machine property 'virtio-mmio-transports' to control the number of virtio-mmio transports instantiated. The default remains
NUM_VIRTIO_TRANSPORTS(32) for backward compatibility. Setting it to 0 allows users to disable virtio-mmio entirely.
Quoted 7 lines
Usage: -machine virt,virtio-mmio-transports=0
Signed-off-by Mohammadfaiz Bawa <[email protected]>---
Changes in v2:
- Renamed property from virtio-transports to virtio-mmio-transports
- Added documentation indocs/system/arm/virt.rst
Applied to target-arm.next, thanks.
-- PMM
Peter Maydell
AppliedQuoted 11 lines · Mohammadfaiz Bawa
Windows ARM64 guests detect virtio-mmio devices declared in ACPI tables even when no backend is attached. This causes "Unknown devices" (ACPI\LNRO0005) to appear in Device Manager.
Until Windows fixes that by supporting, add a new machine property 'virtio-mmio-transports' to control the number of virtio-mmio transports instantiated. The default remains
NUM_VIRTIO_TRANSPORTS(32) for backward compatibility. Setting it to 0 allows users to disable virtio-mmio entirely.
Quoted 8 lines
Usage: -machine virt,virtio-mmio-transports=0
Signed-off-by Mohammadfaiz Bawa <[email protected]>---
Changes in v2:
- Renamed property from virtio-transports to virtio-mmio-transports
- Added documentation indocs/system/arm/virt.rst
Applied to target-arm.next, thanks.
-- PMM