From: Paolo Bonzini Subject: [PATCH kvm-unit-tests 05/18] x86: leave VM setup out of vtd_init Date: Tue, 24 Oct 2017 17:21:32 +0200 Message-ID: <20171024152145.28456-6-pbonzini@redhat.com> References: <20171024152145.28456-1-pbonzini@redhat.com> Cc: drjones@redhat.com, david@redhat.com To: kvm@vger.kernel.org Return-path: Received: from mail-wr0-f196.google.com ([209.85.128.196]:44323 "EHLO mail-wr0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932429AbdJXPV4 (ORCPT ); Tue, 24 Oct 2017 11:21:56 -0400 Received: by mail-wr0-f196.google.com with SMTP id z55so15014595wrz.1 for ; Tue, 24 Oct 2017 08:21:55 -0700 (PDT) In-Reply-To: <20171024152145.28456-1-pbonzini@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Signed-off-by: Paolo Bonzini --- lib/x86/intel-iommu.c | 4 ---- x86/intel-iommu.c | 3 +++ 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/x86/intel-iommu.c b/lib/x86/intel-iommu.c index af92fab..3f3f211 100644 --- a/lib/x86/intel-iommu.c +++ b/lib/x86/intel-iommu.c @@ -12,7 +12,6 @@ #include "intel-iommu.h" #include "libcflat.h" -#include "vm.h" #include "pci.h" #include "atomic.h" #include "alloc_page.h" @@ -360,9 +359,6 @@ void vtd_setup_ioapic_irq(struct pci_dev *dev, int vector, void vtd_init(void) { - setup_vm(); - smp_init(); - vtd_reg_base = ioremap(Q35_HOST_BRIDGE_IOMMU_ADDR, PAGE_SIZE); vtd_dump_init_info(); diff --git a/x86/intel-iommu.c b/x86/intel-iommu.c index 82b8234..f24170d 100644 --- a/x86/intel-iommu.c +++ b/x86/intel-iommu.c @@ -132,6 +132,9 @@ static void vtd_test_ir(void) int main(int argc, char *argv[]) { + setup_vm(); + smp_init(); + vtd_init(); report_prefix_push("vtd_init"); -- 2.14.2