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

Re: [Xen-devel] [RFC] OVMF on PVH



On Wed, Aug 08, 2018 at 04:02:09PM +0100, Anthony PERARD wrote:
> On Thu, Aug 02, 2018 at 04:44:56PM +0100, Wei Liu wrote:
> > On Thu, Aug 02, 2018 at 12:24:35PM +0100, Anthony PERARD wrote:
> > > ## Loading binary at 0x10000 (1MB, like hvmloader on HVM)
> > > 
> > > Right now, the OVMF blob is loaded (by hvmloader) just below 4GB, with
> > > hvmloader moving some RAM around to allow that.  But with the use of an
> > > ELF header, and let libxc load the blob, it was not possible to load the
> > > blob just below 4GB. (Or at least without modification of the toolstack I
> > > guess.) So I've attempted to have OVMF been started from a different place
> > > in memory. Then I had to hack a bit more in order to be able to start OVMF
> > > from two different location (the current one for HVM guest, and a new one
> > > that can be used for PVH). That works fine, I'll just have to find out
> > > what upstream think about that.
> > 
> > If you specify the virt_addr (?) in the ELF header, libxc should know
> > how to deal with that? What is missing in the current toolstack code?
> 
> RAM.
> 
> If I set the ELF header properly so that it is written that the blob
> must be loaded in the guest RAM just below 4G, libxc will not be able to
> do anything because there is no RAM, that space is suppose to be a mem
> hole, or something like that, I forgot the exact detail :(. I think also
> that libxl would try to load other data like the startinfo page past the
> kernel (OVMF here) and that would mean past 4G.
> 
> (In my notes from when I tried, I've written "libxc will not move ram
> like hvmloader would; [and with >4G for the guest] libxc can not map
> anything past 0xfee00000, and I want 0xffe00000", whatever that mean,
> can find out where I found that 0xfee00000 address.)

This is arguably a bug of the current libxc implementation. libxc
should always populate the place where the kernel will be loaded
first, and then populate the rest of the memory map using the
remaining memory.

Given your other reply that mentions that the initial load region is
discarded afterwards because ovmf relocates itself I think I'm OK with
loading it wherever it's easier.

Thanks, Roger.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

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