From: Alex Williamson Subject: Re: KVM & PCI Passthrough Date: Wed, 04 Dec 2013 11:46:18 -0700 Message-ID: <1386182778.25738.363.camel@ul30vt.home> References: <1894763452.20558413.1386180503817.JavaMail.zimbra@innovot.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org To: Phil Daws Return-path: Received: from mx1.redhat.com ([209.132.183.28]:2810 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932867Ab3LDSq2 (ORCPT ); Wed, 4 Dec 2013 13:46:28 -0500 In-Reply-To: <1894763452.20558413.1386180503817.JavaMail.zimbra@innovot.com> Sender: kvm-owner@vger.kernel.org List-ID: On Wed, 2013-12-04 at 18:08 +0000, Phil Daws wrote: > Hello all, > > as performing some tests in my lab with PCI pass-through and not really understanding it. Here is what I have done so far: > > lspci -nn: > > 06:00.0 RAID bus controller [0104]: LSI Logic / Symbios Logic MegaRAID SAS 2108 [Liberator] [1000:0079] (rev 05) > > modprobe pci_stub > echo "1000 0079" > /sys/bus/pci/drivers/pci-stub/new_id > echo "0000:06:00.0" > /sys/bus/pci/devices/0000:00:1b.0/driver/unbind > echo "0000:06:00.0" > /sys/bus/pci/drivers/pci-stub/bind > > I then create the new guest through virt-manager, add the PCI device, but when it tries to start the install it fails straight away. I have checked then IOMMU is enabled: > > dmesg | grep IOMMU > [ 0.000000] Intel-IOMMU: enabled This is not nearly enough output, my properly working Haswell i5-4430 reports: $ dmesg | grep IOMMU [ 0.000000] Intel-IOMMU: enabled [ 0.022767] dmar: IOMMU 0: reg_base_addr fed90000 ver 1:0 cap c0000020660462 ecap f0101a [ 0.023012] dmar: IOMMU 1: reg_base_addr fed91000 ver 1:0 cap d2008020660462 ecap f010da [ 0.023402] IOAPIC id 2 under DRHD base 0xfed91000 IOMMU 1 [ 0.355789] IOMMU 0 0xfed90000: using Queued invalidation [ 0.355878] IOMMU 1 0xfed91000: using Queued invalidation [ 0.355968] IOMMU: Setting RMRR: [ 0.356063] IOMMU: Setting identity map for device 0000:00:02.0 [0xbf000000 - 0xcf1fffff] [ 0.357644] IOMMU: Setting identity map for device 0000:00:1d.0 [0xbc979000 - 0xbc985fff] [ 0.357817] IOMMU: Setting identity map for device 0000:00:1a.0 [0xbc979000 - 0xbc985fff] [ 0.357981] IOMMU: Setting identity map for device 0000:00:14.0 [0xbc979000 - 0xbc985fff] [ 0.358139] IOMMU: Prepare 0-16MiB unity mapping for LPC [ 0.358234] IOMMU: Setting identity map for device 0000:00:1f.0 [0x0 - 0xffffff] Make sure VT-d is enabled in the BIOS and boot with intel_iommu=on. > am running a Intel i7 4440k on a ASUS Z87-K Mobo with virtualization all enabled. Double check your CPU mode, 4440K doesn't exist according to http://ark.intel.com/ The unlocked K models often (typically) do not support VT-d, in which case you're out of luck with this CPU. Thanks, Alex