[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v3 3/8] hvmloader: Set up highmem resouce appropriately if there is no RAM above 4G
>>> On 20.06.13 at 18:33, George Dunlap <george.dunlap@xxxxxxxxxxxxx> wrote: > @@ -244,7 +244,14 @@ void pci_setup(void) > hvm_info->high_mem_pgend += nr_pages; > } > > - high_mem_resource.base = ((uint64_t)hvm_info->high_mem_pgend) << > PAGE_SHIFT; > > + if ( hvm_info->high_mem_pgend ) To be on the safe side I'd make this if ( hvm_info->high_mem_pgend >= (1ull << 32) ) > + high_mem_resource.base = ((uint64_t)hvm_info->high_mem_pgend) << > PAGE_SHIFT; > + else > + high_mem_resource.base = 1ull << 32; > + printf("%sRAM in high memory; setting high_mem resource base to > %x%08x\n", > + hvm_info->high_mem_pgend?"":"No ", > + (uint32_t)(high_mem_resource.base>>32), > + (uint32_t)high_mem_resource.base); Seeing the n-th incarnation of this - mind creating a macro to do the splitting? Jan > high_mem_resource.max = 1ull << cpu_phys_addr(); > mem_resource.base = pci_mem_start; > mem_resource.max = pci_mem_end; _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |