From: Paolo Bonzini Subject: [PATCH kvm-unit-tests 05/10] x86: leave VM setup out of vtd_init Date: Mon, 23 Oct 2017 15:53:29 +0200 Message-ID: <20171023135334.18864-6-pbonzini@redhat.com> References: <20171023135334.18864-1-pbonzini@redhat.com> Cc: drjones@redhat.com, david@redhat.com To: kvm@vger.kernel.org Return-path: Received: from mail-wm0-f68.google.com ([74.125.82.68]:47130 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932270AbdJWNxp (ORCPT ); Mon, 23 Oct 2017 09:53:45 -0400 Received: by mail-wm0-f68.google.com with SMTP id t69so9704631wmt.2 for ; Mon, 23 Oct 2017 06:53:44 -0700 (PDT) In-Reply-To: <20171023135334.18864-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