[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Can't map the page referenced by HVM-DomU CR3 in Dom0
On 19/04/2011 22:58, "david" <david_n@xxxxxx> wrote: >> xc_translate_foreign_address() will convert a guest virtual address into a >> guest physical address. It's not working out for you because guest cr3 >> values are already guest physical addresses. Thus the virtual-to-physical >> conversion you subject the values to is meaningless. > > ahhh, .. I see. I thought the translation is between guest physical and > real physical address. The toolstack deals entirely with guest physical addresses for HVM guests. There's actually no way, and no need, to find out the underlying real physical addresses. > The way to calculate the correct physical frame > number is cr3 >> PAGE_SHIFT corresponding to xen_cr3_to_pfn(cr3) in > public/arch-x86/xen-x86_64.h, right? Yes, although strictly speaking the xen_cr3_to_pfn() macro is intended to be used only with PV guests' cr3 values (the x86_32 version of that macro is not suitable for use with HVM cr3 values). Consider an HVM guest in 32-bit PAE mode -- its CR3 value may not be page aligned. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |