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

Re: [Xen-devel] qemu-xen-dir + PCI passthrough = BOOM



On Wed, Dec 18, 2013 at 02:48:24PM +0000, Anthony PERARD wrote:
> On Mon, Dec 16, 2013 at 10:08:16AM -0500, Konrad Rzeszutek Wilk wrote:
> > On Fri, Dec 06, 2013 at 04:03:10PM +0000, Wei Liu wrote:
> > > On Fri, Dec 06, 2013 at 04:00:18PM +0000, Wei Liu wrote:
> > > [...]
> > > > > Those Xen report something like:
> > > > > (XEN) page_alloc.c:1460:d0 Over-allocation for domain 46: 131329 >
> > > > > 131328
> > > > > (XEN) memory.c:132:d0 Could not allocate order=0 extent: id=46
> > > > > memflags=0 (62 of 64)
> > > > > 
> > > > > ?
> > > > > 
> > > > > (I tryied to reproduce the issue by simply add many emulated e1000 in
> > > > > QEMU :) )
> > > > > 
> 
> > -bash-4.1# lspci -s 01:00.0 -v 
> > 01:00.0 Ethernet controller: Intel Corporation 82576 Gigabit Network 
> > Connection (rev 01)
> >         Subsystem: Intel Corporation Gigabit ET Dual Port Server Adapter
> >         Flags: fast devsel, IRQ 16
> >         Memory at fbc20000 (32-bit, non-prefetchable) [disabled] [size=128K]
> >         Memory at fb800000 (32-bit, non-prefetchable) [disabled] [size=4M]
> >         I/O ports at e020 [disabled] [size=32]
> >         Memory at fbc44000 (32-bit, non-prefetchable) [disabled] [size=16K]
> >         Expansion ROM at fb400000 [disabled] [size=4M]
> 
> BTW, I think this is the issue, the Expansion ROM. qemu-xen will
> allocate memory for it. Will have maybe have to find another way.
> qemu-trad those not seems to allocate memory, but I haven't been very
> far in trying to check that.

And indeed that is the case. The "Fix" below fixes it.


Based on that and this guest config:
disk = [ 'file:/mnt/lab/latest/root_image.iso,hdc:cdrom,r']
memory = 2048
boot="d"
maxvcpus=32
vcpus=1
serial='pty'
vnclisten="0.0.0.0"
name="latest"
vif = [ 'mac=00:0F:4B:00:00:68, bridge=switch' ]
pci = ["01:00.0"]

I can boot the guest.

diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c
index ca2d460..82b3890 100644
--- a/hw/xen/xen_pt.c
+++ b/hw/xen/xen_pt.c
@@ -425,6 +425,7 @@ static int xen_pt_register_regions(XenPCIPassthroughState 
*s)
                    i, r->size, r->base_addr, type);
     }
 
+#if 0
     /* Register expansion ROM address */
     if (d->rom.base_addr && d->rom.size) {
         uint32_t bar_data = 0;
@@ -449,7 +450,7 @@ static int xen_pt_register_regions(XenPCIPassthroughState 
*s)
                    " base_addr=0x%08"PRIx64")\n",
                    d->rom.size, d->rom.base_addr);
     }
-
+#endif
     return 0;
 }
 

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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