From: Daniel Kiper Subject: Re: Relocatable Xen early boot code Date: Fri, 12 Jun 2015 16:43:35 +0200 Message-ID: <20150612144335.GP19315@olila.local.net-space.pl> References: <20150612111409.GJ19315@olila.local.net-space.pl> <557AE7E90200007800084323@mail.emea.novell.com> <20150612135133.GN19315@olila.local.net-space.pl> <557B0169020000780008444D@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1Z3QBO-0005gw-M2 for xen-devel@lists.xenproject.org; Fri, 12 Jun 2015 14:43:46 +0000 Content-Disposition: inline In-Reply-To: <557B0169020000780008444D@mail.emea.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Jan Beulich Cc: andrew.cooper3@citrix.com, keir@xen.org, xen-devel@lists.xenproject.org List-Id: xen-devel@lists.xenproject.org On Fri, Jun 12, 2015 at 02:57:29PM +0100, Jan Beulich wrote: > >>> On 12.06.15 at 15:51, wrote: > > On Fri, Jun 12, 2015 at 01:08:41PM +0100, Jan Beulich wrote: > >> >>> On 12.06.15 at 13:14, wrote: > >> > Here I do not want to discuss GRUB2 and multiboot2 protocol support details > >> > for relocatable images. It is not needed. It is sufficient to know that it > >> > is able to put loaded image anywhere in available memory below 4 GiB. > > Loaded > >> > image is informed about its base address according to multiboot2 protocol > >> > via > >> > special tag. This is new feature not available in upstream GRUB2. I work on > >> > upstreaming it in parallel. Relevant patches will be posted together with > >> > Xen patches. > >> > >> Before going into any detail on what you write later on - if this isn't in > >> upstream grub2, why can't you do what you want to do first without > >> another change needed in the boot loader? In which case, if I'm reading > >> this correctly, you wouldn't need our boot code to become relocatable > >> either. > > > > multiboot protocol (any version) puts image at address as it requests. > > Always, without any exception. So, in our case starting from 1 MiB. > > On legacy BIOS platforms it works. However, on EFI platforms it is not > > always possible because sometimes some parts of EFI boot/runtime services > > live somewhere around 1 MiB. So, first of all we must change multiboot > > protocol behavior (in our case version 2 because it is more flexible) > > and learn it to relocate images into free memory region. On the other > > hand we must learn Xen early boot code to live at different addresses. > > We must do all this changes in GRUB2 and in Xen in parallel. > > Right, I now recall (the huge time difference between individual > steps is of course kind of problematic here). Great! Sorry for "huge time difference" but I was not always able to devote all my time to upstream work or things were complicating more then expected and delaying all stuff. Now it looks that all major issues are solved and I will be able to work most of the time on upstreaming GRUB2 and Xen EFI related stuff. Daniel