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

Re: [Xen-users] domU only see 512MB RAM when enabling PCI passthrough

That patch was for the EFI Dom0 memory recognition, and was patched sometime before 4.2 released (by reversing the if statement). ÂYour xl dmesg shows e820 (and approx. 16G) so I am quite certain that is not the cause of your DomU memory bug.

Can you provide your PV DomU configuration?

I know I've heard about the bug before, usually in the context of over 3GB to a PV domain, but from what I recall it was fixed:

On Mon, Mar 11, 2013 at 6:42 PM, ShadesOfGrey <shades_of_grey@xxxxxxxxxxxxx> wrote:
From Casey Delorme's "Comprehensive Xen Debian Wheezy PCI Passthrough Tutorial", this may be the potential cause of your issue.

EFI Source Modification

Given that I encountered no make errors, I was shocked to find that they still hadn't addressed the grub efi compatibility bug where it fails to recognize available system memory.

The fix for this is a source modification, though they have supposedly added a build process for xen.efi, which would replace the debian.efi generated by grub. I have yet to find adequate instructions to make that work, and even if I did may break adding xen-pciback.hide to the grub configuration, which we need if we are planning to do the easy method of PCI Passthrough.

So, let's open up xen/arch/x86/setup.c with our favorite text editor, and find the line containing ( e820_raw_nrÂ!= 0 ), and make that area look like this:

#if 0
 else if ( e820_raw_nr != 0 )
 memmap_type = "Xen-e820";
 else if ( bootsym(lowmem_kb) )
 memmap_type = "Xen-e801";
 e820_raw[0].addr = 0;
 e820_raw[0].size = bootsym(lowmem_kb) << 10;
 e820_raw[0].type = E820_RAM;
 e820_raw[1].addr = 0x100000;
 e820_raw[1].size = bootsym(highmem_kb) << 10;
 e820_raw[1].type = E820_RAM;
 e820_raw_nr = 2;
 else if ( mbi->flags & MBI_MEMMAP )

Notice we are commenting out a section of code using "if 0", which always evaluates to false, to eliminate the section of e801 mapping which breaks our ram recognition.

I have no idea what kind of adverse affects this has on other systems, but it has worked for me since Xen 4.1.2.

End EFI Source Modification

On 03/08/2013 07:44 PM, Baojun Wang wrote:
Hi list,

I'm trying to run pvlinux (via pvgrub) using pci passthrough (and vga
pass through), xen version is 4.2.1, dom0 & domU kernel are both
3.8.2, I checked the kernel log (DMAR) and the motherboard (H67)
supports vt-d, processor is i7-2600 and it supports vt-d too.

When pci passthrough is not enabled, everything is fine;
but after I enabled pci pass through, domU can only see 512MB RAM (USB
passed from pci-passthrough works, but video/intel didn't work, likely
due to i915 load error from dmesg, everything else is also good).

I googled and found a similar issue is reported at:

But seems there is no follow up how the problem is fixed, how can I
fix the issue?

Below are some links from pastebin.com:

1) native dmesg without loading xen.gz: http://pastebin.com/BTVNTi8D
2) (kernel) dmesg of dom0: http://pastebin.com/DEZ7gfmG
3) (xl) dmesg of dom0: http://pastebin.com/46bR2ngv
4) domU dmesg without pci passthrough: http://pastebin.com/DGZR4NLP
5) domU dmesg with pci passthrough: http://pastebin.com/aujxwys2

I tried xen version 4.2.0 too but still no luck.
My kernel have all xen feature enabled; and I can provide more info if


Xen-users mailing list

Xen-users mailing list

Xen-users mailing list



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