[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Can't see more than 3.5GB of RAM / UEFI / no e820 memory map detected
On 28/08/2012 22:52, Jonathan Tripathy wrote: Anyway, question is moot. I rebuilt my code using your ordering of the if block and it works just fine. All 32GB is detected. I actually agree with your order because as you as, 801 is outdated.On 28/08/2012 22:50, Jonathan Tripathy wrote:Ooops, typo'd the code (I had to recreate the changes as I deleted my source tree). Here is the version I used:On 28/08/2012 22:41, Keir Fraser wrote:On 28/08/2012 22:13, "Jonathan Tripathy" <jonnyt@xxxxxxxxxxx> wrote:Keir Fraser wrote:On 28/08/2012 20:36, "Jonathan Tripathy" <jonnyt@xxxxxxxxxxx> wrote:In this case, I will re-make the patch myself and check it in. Since it is aThanks for the clarification.So from a security/reliability standpoint, nothing will be affected byflipping the if block?It should simply make it more likely that Xen sees all your RAM. ;) -- KeirHi Everyone,I reversed the if block in setup.c and now my server can see the full 32GB of RAM. I haven't submitted a patch yet as we have run into another(possibly unrelated to xen) issue with this server build that we areworking on. Once we complete our full testing, a patch will be submitted :)trivial one. Thanks, KeirThanks KeirNow done. xen-unstable:25786 -- KeirHi Keir,Thanks for doing that. However, the ordering of the if block in my code that I used was slightly different from your commit. Perhaps this doesn't make too much of a difference?Thanksif ( mbi->flags & MBI_MEMMAP ) { memmap_type = "Multiboot-e820"; while ( (bytes < mbi->mmap_length) && (e820_raw_nr < E820MAX) ) { memory_map_t *map = __va(mbi->mmap_addr + bytes); /** This is a gross workaround for a BIOS bug. Some bootloaders do* not write e820 map entries into pre-zeroed memory. This is * okay if the BIOS fills in all fields of the map entry, but * some broken BIOSes do not bother to write the high word of * the length field if the length is smaller than 4GB. We * detect and fix this by flagging sections below 4GB that * appear to be larger than 4GB in size. */ if ( (map->base_addr_high == 0) && (map->length_high != 0) ) { if ( !e820_warn ) { printk("WARNING: Buggy e820 map detected and fixed " "(truncated length fields).\n"); e820_warn = 1; } map->length_high = 0; } e820_raw[e820_raw_nr].addr =((u64)map->base_addr_high << 32) | (u64)map->base_addr_low;e820_raw[e820_raw_nr].size = ((u64)map->length_high << 32) | (u64)map->length_low; e820_raw[e820_raw_nr].type = map->type; e820_raw_nr++; bytes += map->size + 4; } } else if ( mbi->flags & MBI_MEMLIMITS ) { memmap_type = "Multiboot-e801"; e820_raw[0].addr = 0; e820_raw[0].size = mbi->mem_lower << 10; e820_raw[0].type = E820_RAM; e820_raw[1].addr = 0x100000; e820_raw[1].size = mbi->mem_upper << 10; e820_raw[1].type = E820_RAM; e820_raw_nr = 2; } 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 { EARLY_FAIL("Bootloader provided no memory information.\n"); } _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |