[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] PCI passthrough of multiple devices to HVM guest using stub domain not working

  • To: xen-devel@xxxxxxxxxxxxxxxxxxx
  • From: Jason Sonnek <jsonnek@xxxxxxxxx>
  • Date: Wed, 16 Feb 2011 11:19:39 -0600
  • Delivery-date: Wed, 16 Feb 2011 09:21:28 -0800
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=iuqh/o1Pv8acH7qK/RDsjS/MQst94ec4kIlQb60MIv3Au3wV67/wGHwsp+hMa7QnBe KC1NUAIImz8z4ygeF2M0tESj6iWzxLdP7Cvf/4Ayc5jWW/RJlQZcHjEBygCkoftUP6NI Ge2gWtbNtN4HJmJ+XR9Ynqi5JJxWQLeoVUBjM=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

Only the first function of the first device that I pass-through to an
HVM guest using a stub domain successfully registers. If the first
device in the "pci=[....]" line in the configuration file has a single
function, the guest will boot and the first device will be
passed-through successfully, but only none of the devices listed after
the first will work. If the first device in the configuration file has
multiple functions, the guest will hang during start-up.

I'm using Xen 4.0.1 / pv_ops Dom0. Works fine using qemu-dm
in Dom0 instead of stubdom-dm. I've tested this with multiple devices.

Here's an excerpt from the QEMU log showing successful registration of
the first function of a device and failure of the second:

xs_read_watch() -> /local/domain/0/device-model/75/command dm-command
dm-command: hot insert pass-through pci dev
register_real_device: Assigning real physical device 08:00.0 ...
open(/sys/bus/pci/devices/0000:08:00.0/resource, 0)pt_libpci_fixup:
Error: Can't open /sys/bus/pci/devices/0000:08:00.0/resource: I/O
register_real_device: Enable MSI translation via per device option
register_real_device: Disable power management
warning: pt_iomul not supported in stubdom 08:00.0
pt_register_regions: IO region registered (size=0x00020000 base_addr=0xf9600000)
pt_register_regions: IO region registered (size=0x00000020 base_addr=0x0000bf80)
pt_register_regions: IO region registered (size=0x00004000 base_addr=0xf9640000)
pt_msix_init: get MSI-X table bar base f9640000
open(/dev/mem) -> 12
pt_msix_init: table_off = 0, total_entries = 10
pt_msix_init: errno = 5
pt_msix_init: mapping physical MSI-X table to 2807000
pt_msi_setup: Error: Mapping of MSI failed.
pt_enable_msi_translate: Error: MSI-INTx translation MSI setup failed, fallback
pci_intx: intx=1
register_real_device: Real physical device 08:00.0 registered successfuly!
IRQ type = INTx
xs_read_watch() -> /local/domain/0/device-model/75/command dm-command
xs_read(/local/domain/0/device-model/75/command): ENOENT
pcifront_watches: backend state changed:
/local/domain/0/backend/pci/76/0/state 7
pcifront_watches: writing device/pci/0/state 7
pcifront_watches: backend state changed:
/local/domain/0/backend/pci/76/0/state 5
pcifront_watches: done waiting
close pci: backend at /local/domain/0/backend/pci/76/0
xs_read_watch() -> /local/domain/0/device-model/75/command dm-command
dm-command: hot insert pass-through pci dev
register_real_device: Assigning real physical device 08:00.1 ...
register_real_device: Error: couldn't locate device in libpci structures
xs_read_watch() -> /local/domain/0/device-model/75/command dm-command
xs_read(/local/domain/0/device-model/75/command): ENOENT

Any suggestions/assistance greatly appreciated.


Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.