From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:42377) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RzZOI-0008C0-7S for qemu-devel@nongnu.org; Mon, 20 Feb 2012 14:59:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RzZOG-0005ly-FY for qemu-devel@nongnu.org; Mon, 20 Feb 2012 14:59:18 -0500 Received: from www.vido.info ([78.47.43.171]:42786 helo=mail.vido.info) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RzZOG-0005lj-2d for qemu-devel@nongnu.org; Mon, 20 Feb 2012 14:59:16 -0500 Message-ID: <4F42A601.7000701@vido.info> Date: Mon, 20 Feb 2012 20:58:57 +0100 From: Tobias Geiger MIME-Version: 1.0 References: <1329498525-8454-1-git-send-email-anthony.perard@citrix.com> <201202201151.12291.tobias.geiger@vido.info> <201202201711.11807.tobias.geiger@vido.info> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [Xen-devel] [PATCH V7 00/11] Xen PCI Passthrough List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony PERARD Cc: xen-devel@lists.xensource.com, QEMU-devel , Stefano Stabellini Hi With the patch you mentioned, xl create looks more familiar: libxl: error: libxl_pci.c:756:libxl__device_pci_reset: write to /sys/bus/pci/devices/0000:03:00.0/reset returned -1: Invalid argument libxl: error: libxl_pci.c:756:libxl__device_pci_reset: write to /sys/bus/pci/devices/0000:03:00.1/reset returned -1: Invalid argument This is actually "normal", at least compared to traditional qemu-dm - i guess due to missing FLR (Bios is capable, but Card not i assume). Anyhow - the downside of the patch is, qemu doesnt even start :) This is qemu-dm.log (with debugging enabled): [00:06.0] pci_intx: intx=1 [00:06.0] pt_initfn: Real physical device 03:00.0 registered successfuly! [00:07.0] pt_initfn: Assigning real physical device 03:00.1 to devfn 0x38 [00:07.0] pt_register_regions: IO region 0 registered (size=0x00004000 base_addr=0xc3120000 type: 0) [00:07.0] pci_intx: intx=2 [00:07.0] pt_initfn: Real physical device 03:00.1 registered successfuly! [00:08.0] pt_initfn: Assigning real physical device 00:1d.0 to devfn 0x40 [00:08.0] pt_register_regions: IO region 4 registered (size=0x00000020 base_addr=0x00005080 type: 0x1) [00:08.0] pci_intx: intx=1 [00:08.0] pt_initfn: Real physical device 00:1d.0 registered successfuly! [00:09.0] pt_initfn: Assigning real physical device 00:1d.1 to devfn 0x48 [00:09.0] pt_register_regions: IO region 4 registered (size=0x00000020 base_addr=0x00005060 type: 0x1) [00:09.0] pci_intx: intx=2 [00:09.0] pt_initfn: Real physical device 00:1d.1 registered successfuly! [00:0a.0] pt_initfn: Assigning real physical device 00:1d.2 to devfn 0x50 [00:0a.0] pt_register_regions: IO region 4 registered (size=0x00000020 base_addr=0x00005040 type: 0x1) [00:0a.0] pci_intx: intx=3 [00:0a.0] pt_initfn: Real physical device 00:1d.2 registered successfuly! [00:0b.0] pt_initfn: Assigning real physical device 00:1d.7 to devfn 0x58 [00:0b.0] pt_register_regions: IO region 0 registered (size=0x00000400 base_addr=0xc3321000 type: 0) [00:0b.0] pci_intx: intx=1 [00:0b.0] pt_initfn: Real physical device 00:1d.7 registered successfuly! [00:06.0] pt_pci_read_config: address=0x000a val=0x00000300 len=2 [00:06.0] pt_pci_read_config: address=0x0000 val=0x00001002 len=2 [00:06.0] pt_pci_read_config: address=0x0002 val=0x00006718 len=2 [00:06.0] pt_pci_read_config: address=0x0010 val=0x0000000c len=4 [00:06.0] pt_pci_write_config: address=0x0010 val=0xffffffff len=4 [00:06.0] pt_iomem_map: BAR 0, e_phys=0xffffffffffffffff maddr=0xe0000000 len=0x10000000 first_map=1 [00:06.0] pt_pci_read_config: address=0x0010 val=0xf000000c len=4 [00:06.0] pt_pci_write_config: address=0x0010 val=0x0000000c len=4 [00:06.0] pt_iomem_map: BAR 0, e_phys=0xffffffffffffffff maddr=0xe0000000 len=0x10000000 first_map=0 [00:06.0] pt_pci_read_config: address=0x0018 val=0x00000004 len=4 [00:06.0] pt_pci_write_config: address=0x0018 val=0xffffffff len=4 [00:06.0] pt_iomem_map: BAR 2, e_phys=0xffffffffffffffff maddr=0xc3100000 len=0x20000 first_map=1 [00:06.0] pt_pci_read_config: address=0x0018 val=0xfffe0004 len=4 [00:06.0] pt_pci_write_config: address=0x0018 val=0x00000004 len=4 [00:06.0] pt_iomem_map: BAR 2, e_phys=0xffffffffffffffff maddr=0xc3100000 len=0x20000 first_map=0 [00:06.0] pt_pci_read_config: address=0x0020 val=0x00000001 len=4 [00:06.0] pt_pci_write_config: address=0x0020 val=0xffffffff len=4 [00:06.0] pt_ioport_map: BAR 4, e_phys=0xffffffffffffffff pio_base=0x2000 len=256 first_map=1 [00:06.0] pt_pci_read_config: address=0x0020 val=0xffffff01 len=4 [00:06.0] pt_pci_write_config: address=0x0020 val=0x00000001 len=4 [00:06.0] pt_ioport_map: BAR 4, e_phys=0xffffffffffffffff pio_base=0x2000 len=256 first_map=0 [00:06.0] pt_pci_read_config: address=0x0024 val=0x00000000 len=4 [00:06.0] pt_pci_write_config: address=0x0024 val=0xffffffff len=4 [00:06.0] pt_pci_read_config: address=0x0024 val=0x00000000 len=4 [00:06.0] pt_pci_write_config: address=0x0024 val=0x00000000 len=4 [00:06.0] pt_pci_read_config: address=0x0030 val=0x00000000 len=4 [00:06.0] pt_pci_write_config: address=0x0030 val=0xffffffff len=4 [00:06.0] pt_iomem_map: BAR 6, e_phys=0xffffffffffffffff maddr=0xc3140000 len=0x20000 first_map=1 [00:06.0] pt_pci_read_config: address=0x0030 val=0xfffe0001 len=4 [00:06.0] pt_pci_write_config: address=0x0030 val=0x00000000 len=4 [00:06.0] pt_iomem_map: BAR 6, e_phys=0xffffffffffffffff maddr=0xc3140000 len=0x20000 first_map=0 [00:06.0] pt_pci_read_config: address=0x003d val=0x00000001 len=1 [00:06.0] pt_pci_write_config: address=0x003c val=0x0000000b len=1 [00:06.0] pt_pci_read_config: address=0x0004 val=0x00000000 len=2 [00:06.0] pt_pci_write_config: address=0x0004 val=0x00000004 len=2 qemu-system-x86_64: /usr/src/xen-with-upstream-qemu-patch/upstream-qemu/qemu/memory.c:1378: memory_region_del_subregion: Assertion `subregion->parent == mr' failed. Waiting for data... Am 20.02.2012 18:08, schrieb Anthony PERARD: > On Mon, Feb 20, 2012 at 16:11, Tobias Geiger wrote: >> My Domu (Win7_64) boots fine, but 2 of my 6 passed-through pcidevices dont get >> passed through at all: >> >> libxl: error: libxl_pci.c:756:libxl__device_pci_reset: write to >> /sys/bus/pci/devices/0000:03:00.0/reset returned -1: Invalid argument >> libxl: error: libxl_qmp.c:239:qmp_handle_error_response: received an error >> message from QMP server: Device 'xen-pci-passthrough' could not be initialized >> libxl: error: libxl_pci.c:756:libxl__device_pci_reset: write to >> /sys/bus/pci/devices/0000:03:00.1/reset returned -1: Invalid argument >> libxl: error: libxl_qmp.c:239:qmp_handle_error_response: received an error >> message from QMP server: Device 'xen-pci-passthrough' could not be initialized > These two errors are probably because my patch series depend on one > other patch sent earlier: > http://lists.xen.org/archives/html/xen-devel/2012-02/msg01027.html > >> The other 4 PCI-Ids (USB Controller) get passed through, but the USB-Devices >> attached to them are "Not Working" according to Windows Device-Manager. >> >> All Devices worked with the old qemu-dm (traditional). >> >> Anything i can do to debug this further? > You can send the log of qemu ( /var/log/xen/qemu-dm-$vm_name.log ). > There is also a way to have more from QEMU by decommenting this two lines: > /* #define PT_LOGGING_ENABLED */ > /* #define PT_DEBUG_PCI_CONFIG_ACCESS */ > in hw/xen_pci_passthrough.h > > Thanks for the testing, >