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

[Xen-devel] Re: Xen 3.4 multi-function pass-through tree, isn't working...



On Mon, Jul 20, 2009 at 03:11:29PM +0300, Tom Rotenberg wrote:
> This setup worked with the plain xen 3.4 tree.
> No custom stuff in /etc/xen/hvm.
> 
> I took a look at the bug, and wrote a workaround for it. Take a look,
> and tell if it's ok:
> 
> diff -r 776ab1bec020 tools/python/xen/xend/server/pciif.py
> --- a/tools/python/xen/xend/server/pciif.py     Sun Jul 19 11:53:11 2009 -0400
> +++ b/tools/python/xen/xend/server/pciif.py     Mon Jul 20 08:17:34 2009 -0400
> @@ -499,7 +499,13 @@
>          num_devs = int(self.readBackend(devid, 'num_devs'))
>          new_num_devs = 0
>          for i in range(num_devs):
> -            state = int(self.readBackend(devid, 'state-%i' % i))
> +            try:
> +                state = int(self.readBackend(devid, 'state-%i' % i))
> +            except:
> +                state = xenbusState['Unknown']
> +
>              if state == xenbusState['Closing']:
>                  # Detach I/O resources.
>                  pci_dev = parse_pci_name(self.readBackend(devid, 'dev-%i' % 
> i))
> 
> What do u think this bug is caused from?

Hi Tom,

your work around seems entirely reasonable, but I am still puzzled at
how your system gets into this state. I'm having no luck reproducing it
here.

I have the following passed to the dom0 kernel at boot:

root=/dev/mapper/sam-root_x86_64 console=ttyS0 loglevel=8 ro 
pciback.hide=(01:00.0)(01:00.1)(00:1b.0)(00:1a.0)(00:1a.1)(00:1a.7)(00:1d.0)(00:1d.1)(00:1d.2)(00:1d.7)(07:b.0)(07:04.0)
 reassign_resources reassigndev=00:1d.7

And I'm starting a domU with all USB devices passed-through using:

xm create -c /home/horms/hvm xen_platform_pci=0 pci='00:1a.0' pci='00:1a.1' 
pci='00:1a.7' pci='00:1d.0' pci='00:1d.1' pci='00:1d.2' pci='00:1d.7'

To test multi-function pass-through I also tried:

xm create -c /home/horms/hvm xen_platform_pci=0 pci='00:1a.*' pci='00:1d.*'

/home/horms/hvm is as follows:

import os, re
arch = os.uname()[4]
if re.search('64', arch):
    arch_libdir = 'lib64'
else:
    arch_libdir = 'lib'
kernel = "/usr/lib/xen/boot/hvmloader"
builder='hvm'
memory = 128
name = "debian"
disk = [ 'file:/home/horms/projects/xen/media/debian-unstable.disk,hda,w' ]
boot='c'
device_model = '/usr/' + arch_libdir + '/xen/bin/qemu-dm'
sdl=0
opengl=0
vnc=1
vnclisten="0.0.0.0"
vncunused=1
nographic=0
stdvga=0
serial='pty'

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

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