From mboxrd@z Thu Jan 1 00:00:00 1970 From: Roy Franz Subject: Re: [PATCH V4 04/15] Add architecture functions for pre/post ExitBootServices Date: Fri, 12 Sep 2014 09:57:01 -0700 Message-ID: References: <1410310325-4509-1-git-send-email-roy.franz@linaro.org> <1410310325-4509-5-git-send-email-roy.franz@linaro.org> <5411CA240200007800033F2D@mail.emea.novell.com> <5412B81902000078000344E5@mail.emea.novell.com> <1410515187.567.26.camel@kazak.uk.xensource.com> <5412DFE2020000780003468B@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2396820899450836375==" Return-path: In-Reply-To: <5412DFE2020000780003468B@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: keir , Ian Campbell , tim , xen-devel , Stefano Stabellini , Fu Wei List-Id: xen-devel@lists.xenproject.org --===============2396820899450836375== Content-Type: multipart/alternative; boundary=001a1133b89086a9140502e12c56 --001a1133b89086a9140502e12c56 Content-Type: text/plain; charset=UTF-8 On Fri, Sep 12, 2014 at 2:58 AM, Jan Beulich wrote: > >>> On 12.09.14 at 11:46, wrote: > > On Fri, 2014-09-12 at 08:08 +0100, Jan Beulich wrote: > >> >>> On 11.09.14 at 19:44, wrote: > >> > On Thu, Sep 11, 2014 at 7:13 AM, Jan Beulich > wrote: > >> >>>>> On 10.09.14 at 02:51, wrote: > >> >>> status = efi_bs->ExitBootServices(ImageHandle, mmap_key); > >> >>> if ( EFI_ERROR(status) ) > >> >>> PrintErrMesg(L"Cannot exit boot services", status); > >> >>> > >> >>> - /* Adjust pointers into EFI. */ > >> >>> - efi_ct = (void *)efi_ct + DIRECTMAP_VIRT_START; > >> >>> -#ifdef USE_SET_VIRTUAL_ADDRESS_MAP > >> >>> - efi_rs = (void *)efi_rs + DIRECTMAP_VIRT_START; > >> >>> -#endif > >> >>> - efi_memmap = (void *)efi_memmap + DIRECTMAP_VIRT_START; > >> >>> - efi_fw_vendor = (void *)efi_fw_vendor + DIRECTMAP_VIRT_START; > >> >>> - > >> >>> - efi_arch_relocate_image(__XEN_VIRT_START - xen_phys_start); > >> >> > >> >> Up to here I don't see anything arch-specific again. > >> > This is due to runtime services not being implemented. The "efi_rs" > >> > variable is defined in the runtime services > >> > file runtime.c, which is not yet ported to ARM. > >> > > >> > Short of including ARM runtime service support in the patchset, how > >> > would you like this handled? > >> > >> As said before, everything that's generic but not used/usable on > >> ARM right now should stay here, but get made conditional in one > >> or another way. > > > > So in this case a HAVE_EFI_RUNTIMESERVICES ifdef would work? > > Yes (except that in the case I would use NEED_ or WANT_ instead > of HAVE_). But considering this is intended to be temporary, I'd > even be fine with just using CONFIG_ARM or alike here. > > Jan > > OK, I'll move this back. Just having the #ifdefs in runtime.c will help a lot. Is commenting the #ifef like so acceptable: #ifndef CONFIG_ARM /* TODO - disabled until EFI runtime services implemented */ Thanks, Roy --001a1133b89086a9140502e12c56 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On F= ri, Sep 12, 2014 at 2:58 AM, Jan Beulich <JBeulich@suse.com>= wrote:
>>> On 12.09.14 at 11:46, <Ian.Campbell@citrix.com> wrote:
> On Fri, 2014-09-12 at 08:08 +0100, Jan Beulich wrote:
>> >>> On 11.09.14 at 19:44, <roy.franz@linaro.org> wrote:
>> > On Thu, Sep 11, 2014 at 7:13 AM, Jan Beulich <JBeulich@suse.com> wrote:
>> >>>>> On 10.09.14 at 02:51, <roy.franz@linaro.org> wrote:
>> >>>=C2=A0 =C2=A0 =C2=A0 status =3D efi_bs->ExitBootSer= vices(ImageHandle, mmap_key);
>> >>>=C2=A0 =C2=A0 =C2=A0 if ( EFI_ERROR(status) )
>> >>>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 PrintErrMesg(L"= ;Cannot exit boot services", status);
>> >>>
>> >>> -=C2=A0 =C2=A0 /* Adjust pointers into EFI. */
>> >>> -=C2=A0 =C2=A0 efi_ct =3D (void *)efi_ct + DIRECTMAP_= VIRT_START;
>> >>> -#ifdef USE_SET_VIRTUAL_ADDRESS_MAP
>> >>> -=C2=A0 =C2=A0 efi_rs =3D (void *)efi_rs + DIRECTMAP_= VIRT_START;
>> >>> -#endif
>> >>> -=C2=A0 =C2=A0 efi_memmap =3D (void *)efi_memmap + DI= RECTMAP_VIRT_START;
>> >>> -=C2=A0 =C2=A0 efi_fw_vendor =3D (void *)efi_fw_vendo= r + DIRECTMAP_VIRT_START;
>> >>> -
>> >>> -=C2=A0 =C2=A0 efi_arch_relocate_image(__XEN_VIRT_STA= RT - xen_phys_start);
>> >>
>> >> Up to here I don't see anything arch-specific again.<= br> >> > This is due to runtime services not being implemented.=C2=A0 = The "efi_rs"
>> > variable is defined in the runtime services
>> > file runtime.c, which is not yet ported to ARM.
>> >
>> > Short of including ARM runtime service support in the patchse= t, how
>> > would you like this handled?
>>
>> As said before, everything that's generic but not used/usable = on
>> ARM right now should stay here, but get made conditional in one >> or another way.
>
> So in this case a HAVE_EFI_RUNTIMESERVICES ifdef would work?

Yes (except that in the case I would use NEED_ or WANT_ instead=
of HAVE_). But considering this is intended to be temporary, I'd
even be fine with just using CONFIG_ARM or alike here.

Jan

OK, I'll move this back. =C2=A0Just= having the #ifdefs in runtime.c will help a lot.

= Is commenting the #ifef like so acceptable:

#ifnde= f CONFIG_ARM =C2=A0/* TODO - disabled until EFI runtime services implemente= d */

Thanks,
Roy


--001a1133b89086a9140502e12c56-- --===============2396820899450836375== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============2396820899450836375==--