[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 57/57] hw/i386/amd_iommu: Add description/category to TYPE_AMD_IOM
From: |
Michael S. Tsirkin |
Subject: |
[PULL 57/57] hw/i386/amd_iommu: Add description/category to TYPE_AMD_IOMMU_PCI |
Date: |
Tue, 5 Oct 2021 12:04:53 -0400 |
From: Philippe Mathieu-Daudé <f4bug@amsat.org>
TYPE_AMD_IOMMU_PCI is user-creatable but not well described.
Implement its class_init() handler to add it to the 'Misc
devices' category, and add a description.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20210926175648.1649075-4-f4bug@amsat.org>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
hw/i386/amd_iommu.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/hw/i386/amd_iommu.c b/hw/i386/amd_iommu.c
index 9014690ba3..9242a0d3ed 100644
--- a/hw/i386/amd_iommu.c
+++ b/hw/i386/amd_iommu.c
@@ -1621,10 +1621,19 @@ static const TypeInfo amdvi_sysbus = {
.class_init = amdvi_sysbus_class_init
};
+static void amdvi_pci_class_init(ObjectClass *klass, void *data)
+{
+ DeviceClass *dc = DEVICE_CLASS(klass);
+
+ set_bit(DEVICE_CATEGORY_MISC, dc->categories);
+ dc->desc = "AMD IOMMU (AMD-Vi) DMA Remapping device";
+}
+
static const TypeInfo amdvi_pci = {
.name = TYPE_AMD_IOMMU_PCI,
.parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(AMDVIPCIState),
+ .class_init = amdvi_pci_class_init,
.interfaces = (InterfaceInfo[]) {
{ INTERFACE_CONVENTIONAL_PCI_DEVICE },
{ },
--
MST
- [PULL 48/57] acpi: remove no longer used build_header(), (continued)
- [PULL 48/57] acpi: remove no longer used build_header(), Michael S. Tsirkin, 2021/10/05
- [PULL 45/57] acpi: arm/virt: build_spcr: use acpi_table_begin()/acpi_table_end() instead of build_header(), Michael S. Tsirkin, 2021/10/05
- [PULL 49/57] acpi: AcpiGenericAddress no longer used to map/access fields of MMIO, drop packed attribute, Michael S. Tsirkin, 2021/10/05
- [PULL 51/57] hw/i386/acpi: fix conflicting IO address range for acpi pci hotplug in q35, Michael S. Tsirkin, 2021/10/05
- [PULL 56/57] hw/i386/amd_iommu: Rename SysBus specific functions as amdvi_sysbus_X(), Michael S. Tsirkin, 2021/10/05
- [PULL 22/57] acpi: build_mcfg: use acpi_table_begin()/acpi_table_end() instead of build_header(), Michael S. Tsirkin, 2021/10/05
- [PULL 55/57] hw/i386/amd_iommu: Rename amdviPCI TypeInfo, Michael S. Tsirkin, 2021/10/05
- [PULL 53/57] virtio-balloon: Fix page-poison subsection name, Michael S. Tsirkin, 2021/10/05
- [PULL 54/57] nvdimm: release the correct device list, Michael S. Tsirkin, 2021/10/05
- [PULL 52/57] bios-tables-test: Update ACPI DSDT table golden blobs for q35, Michael S. Tsirkin, 2021/10/05
- [PULL 57/57] hw/i386/amd_iommu: Add description/category to TYPE_AMD_IOMMU_PCI,
Michael S. Tsirkin <=
- [PULL 27/57] acpi: x86: build_dsdt: use acpi_table_begin()/acpi_table_end() instead of build_header(), Michael S. Tsirkin, 2021/10/05
- [PULL 33/57] acpi: build_waet: use acpi_table_begin()/acpi_table_end() instead of build_header(), Michael S. Tsirkin, 2021/10/05
- Re: [PULL 00/57] pc,pci,virtio: features, fixes, Richard Henderson, 2021/10/05
- Re: [PULL 00/57] pc,pci,virtio: features, fixes, Michael S. Tsirkin, 2021/10/05
- Re: [PULL 00/57] pc,pci,virtio: features, fixes, Richard Henderson, 2021/10/05
- Re: [PULL 00/57] pc,pci,virtio: features, fixes, Jason Wang, 2021/10/10