Re: [kvm-unit-tests PATCH v2 03/17] x86 UEFI: Copy code from GNU-EFI

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

 



On Mon, Oct 04, 2021 at 03:09:23PM -0700, Zixuan Wang wrote:
> On Mon, Oct 4, 2021 at 5:46 AM Andrew Jones <drjones@xxxxxxxxxx> wrote:
> >
> > On Fri, Aug 27, 2021 at 03:12:08AM +0000, Zixuan Wang wrote:
> > > +More details can be found in `GNU-EFI/README.gnuefi`, section "Building
> > > +Relocatable Binaries".
> > > +
> > > +KVM-Unit-Tests follows a similar build process, but does not link with GNU-EFI
> > > +library.
> >
> > So, for AArch64, I also want to drop the gnu-efi dependency of my original
> > PoC. My second PoC, which I haven't finished, took things a bit further
> > than this does, though. I was integrating a PE/COFF header and linker
> > script changes directly into the kvm-unit-tests code rather than copying
> > these files over.
> >
> > Thanks,
> > drew
> >
> 
> This approach sounds really interesting. Is there a public repo for
> this new PoC?

Not yet, but reviewing this series has inspired me to reprioritize that
work. I'll try to get it dusted off, improved, and published somewhere.

> 
> I think the self-relocation code is the most important one in this
> patch. If we can avoid or rewrite the self-relocation process, then we
> can pretty much avoid copying GNU-EFI files.

Yup. AArch64 already has a simple relocator (only does R_AARCH64_RELATIVE)
in cstart64.S::start. I also wrote a R_PPC_RELATIVE relocator for ppc in
C, see powerpc/reloc64.c. But, if the gnu-efi one is better for x86, then
I don't see much problem in importing it.

Thanks,
drew




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux