From: Chris Wright Subject: Re: PCI passthrough resource remapping Date: Tue, 30 Mar 2010 17:59:42 -0700 Message-ID: <20100331005942.GV11934@x200.localdomain> References: <3b1f68ef1003291023w533f7000r1ae1fe6a5226c5c3@mail.gmail.com> <3b1f68ef1003291600t1175f794vd3f47cdafca48a8@mail.gmail.com> <20100329234752.GM3204@x200.localdomain> <3b1f68ef1003291721v6fcb01edha4f0424ba0ab24f8@mail.gmail.com> <20100330020805.GS3204@x200.localdomain> <3b1f68ef1003301527p2dd9928alf2f6ead85d678634@mail.gmail.com> <36262BE7-860A-4722-B40C-E2903074BB14@suse.de> <3b1f68ef1003301652g3f8d0ac2r21a6c5ab81ed2800@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Alexander Graf , Chris Wright , kvm list To: Kenni Lund Return-path: Received: from mx1.redhat.com ([209.132.183.28]:20323 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753621Ab0CaA7u (ORCPT ); Tue, 30 Mar 2010 20:59:50 -0400 Content-Disposition: inline In-Reply-To: <3b1f68ef1003301652g3f8d0ac2r21a6c5ab81ed2800@mail.gmail.com> Sender: kvm-owner@vger.kernel.org List-ID: * Kenni Lund (kenni@kelu.dk) wrote: > 2010/3/31 Alexander Graf : > > The easiest thing coming to mind is to unplug the ivtv card for now. It's really only to verify that the patch does something useful :-). > > This was not sufficient. Same issue with the ivtv card unplugged...if > I interpret the content of /proc/interrupt correctly, the USB PCI > cards uses 4 IRQs and out of these three IRQs are still shared with > other components. > > The card uses IRQ 16, 18, 19, 20: > pci-stub 0000:02:01.0: PCI INT B -> GSI 18 (level, low) -> IRQ 18 > pci-stub 0000:02:01.1: PCI INT C -> GSI 16 (level, low) -> IRQ 16 > pci-stub 0000:02:01.2: PCI INT D -> GSI 20 (level, low) -> IRQ 20 > pci-stub 0000:02:01.3: PCI INT A -> GSI 19 (level, low) -> IRQ 19 > > Only IRQ 20 gets "kvm_assigned_intx_device" after > unbinding+binding+qemu-kvm launch: What is your qemu command line? It's acting as if function .2 (one of the ochi controllers) is generating the interrupt rather than .3 (the ehci controller). And indeed, there is no handler to ack that interrupt (just the likely on-board uhci one). before: 19: 0 0 0 0 IO-APIC-fasteoi ehci_hcd:usb3, uhci_hcd:usb9 20: 0 0 0 0 IO-APIC-fasteoi ohci_hcd:usb12 after: 19: 75010 73438 76479 75074 IO-APIC-fasteoi uhci_hcd:usb9 20: 0 0 0 0 IO-APIC-fasteoi kvm_assigned_intx_device Can you unbind uhci_hcd:usb9 and then give both .2 and .3 to the guest? thanks, -chris