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

Re: EFI executable corruption when live patching is turned off


  • To: Trammell Hudson <hudson@xxxxxxxx>, Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • Date: Wed, 5 Aug 2020 19:30:54 +0100
  • Authentication-results: esa4.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
  • Cc: Ross Lagerwall <ross.lagerwall@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
  • Delivery-date: Wed, 05 Aug 2020 18:31:47 +0000
  • Ironport-sdr: 0QLZ0NTlHQ9EPDseLviPBGYrz4w1SDXsh8SWacOwYnqIMeeKQINQDT0rCebWJ1QLcQ0arrLulj EtIZMQj6wvdjVzxW5KY3euCxt3JlExtpyByPNPtv/+kmklffSbCcQ9jGGS00Ns5jCvxeAfHpca HidgBqgpbHFWJmyt38Ts2BMt7W31pS/Fp63v+vFlPoiCW8i3nMa9EDEkdGQXartF4pP+53matN 5kpaU/N+qJiT7nnUgfbJJesz3tjpV8Zcj2wG1XoX+zORbNnZbnxLtesO5Oy7qx+LBLKsXAWGJg ewY=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 05/08/2020 19:19, Trammell Hudson wrote:
> When building xen from head with almost any combination of options, the 
> resulting xen.efi seems properly formed. When CONFIG_LIVEPATCH is turned off, 
> however, the resulting xen.efi is corrupted in some way and binutils no 
> longer wants to work with it:
>
> ~/build/xen-clean/xen$ git rev-parse HEAD
> 81fd0d3ca4b2cd309403c6e8da662c325dd35750
> ~/build/xen-clean/xen$ diff .config.orig .config
> 71,72c71
> < CONFIG_LIVEPATCH=y
> < CONFIG_FAST_SYMBOL_LOOKUP=y
> ---
>> # CONFIG_LIVEPATCH is not set
> 105a105
>> # CONFIG_COVERAGE is not set
> ~/build/xen-clean/xen$ objcopy xen-orig.efi test.efi
> ~/build/xen-clean/xen$ objcopy xen.efi test.efi
> objcopy: test.efi: Data Directory size (1c) exceeds space left in section (18)
> objcopy: test.efi: error copying private BFD data: file in wrong format
> ~/build/xen-clean/xen$ objcopy --version | head -1
> GNU objcopy (GNU Binutils for Ubuntu) 2.34
>
>
> I spent most of today unsuccessfully trying to figure out what was different 
> between the builds (on multiple build host OS with different binutils), so 
> I'm hoping that perhaps someone else has seen this problem.

CC'ing appropriate maintainers.

The difference caused by CONFIG_LIVEPATCH will probably be the logic to
embed the GNU BuildID, which for xen.efi takes a trip through .bin/.ihex
immediately prior to the final link.

~Andrew



 


Rackspace

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