diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2018-01-19 10:17:20 +0000 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2018-01-19 10:17:20 +0000 |
| commit | 3e5bdc6573edf0585e4085e6a4e349b135abf3b4 (patch) | |
| tree | d5a30ac7e2374d362cc7a927665d1938ed1e03ba /hw/i386/amd_iommu.c | |
| parent | b4d6ed1c5ae519d3efb5297be3ef6625ca2a20f4 (diff) | |
| parent | f4bf56fb78ed0e9f60fa1ed656c14ff4c494da5a (diff) | |
| download | focaccia-qemu-3e5bdc6573edf0585e4085e6a4e349b135abf3b4.tar.gz focaccia-qemu-3e5bdc6573edf0585e4085e6a4e349b135abf3b4.zip | |
Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging
pc, pci, virtio: features, fixes, cleanups A bunch of fixes, cleanus and new features all over the place. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> # gpg: Signature made Thu 18 Jan 2018 20:41:03 GMT # gpg: using RSA key 0x281F0DB8D28D5469 # gpg: Good signature from "Michael S. Tsirkin <mst@kernel.org>" # gpg: aka "Michael S. Tsirkin <mst@redhat.com>" # Primary key fingerprint: 0270 606B 6F3C DF3D 0B17 0970 C350 3912 AFBE 8E67 # Subkey fingerprint: 5D09 FD08 71C8 F85B 94CA 8A0D 281F 0DB8 D28D 5469 * remotes/mst/tags/for_upstream: (29 commits) vhost: remove assertion to prevent crash vhost-user: fix misaligned access to payload vhost-user: factor out msg head and payload tests: acpi: add comments to fetch_rsdt_referenced_tables/data->tables usage tests: acpi: rename test_acpi_tables()/test_dst_table() to reflect its usage tests: acpi: init table descriptor in test_dst_table() tests: acpi: move tested tables array allocation outside of test_acpi_dsdt_table() x86_iommu: check if machine has PCI bus x86_iommu: Move machine check to x86_iommu_realize() vhost-user-test: use init_virtio_dev in multiqueue test vhost-user-test: make features mask an init_virtio_dev() argument vhost-user-test: setup virtqueues in all tests vhost-user-test: extract read-guest-mem test from main loop vhost-user-test: fix features mask hw/acpi-build: Make next_base easy to follow ACPI/unit-test: Add a testcase for RAM allocation in numa node hw/pci-bridge: fix QEMU crash because of pcie-root-port intel-iommu: Extend address width to 48 bits intel-iommu: Redefine macros to enable supporting 48 bit address width vhost-user: fix multiple queue specification ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/i386/amd_iommu.c')
| -rw-r--r-- | hw/i386/amd_iommu.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/hw/i386/amd_iommu.c b/hw/i386/amd_iommu.c index eeaf0e0aa8..63d46ff6ee 100644 --- a/hw/i386/amd_iommu.c +++ b/hw/i386/amd_iommu.c @@ -1144,18 +1144,9 @@ static void amdvi_realize(DeviceState *dev, Error **err) AMDVIState *s = AMD_IOMMU_DEVICE(dev); X86IOMMUState *x86_iommu = X86_IOMMU_DEVICE(dev); MachineState *ms = MACHINE(qdev_get_machine()); - MachineClass *mc = MACHINE_GET_CLASS(ms); - PCMachineState *pcms = - PC_MACHINE(object_dynamic_cast(OBJECT(ms), TYPE_PC_MACHINE)); - PCIBus *bus; - - if (!pcms) { - error_setg(err, "Machine-type '%s' not supported by amd-iommu", - mc->name); - return; - } + PCMachineState *pcms = PC_MACHINE(ms); + PCIBus *bus = pcms->bus; - bus = pcms->bus; s->iotlb = g_hash_table_new_full(amdvi_uint64_hash, amdvi_uint64_equal, g_free, g_free); |