coreboot/src
Felix Held 3b89c95906 soc/amd/*/Makefile: fix readelf parameters to get bootblock size
This ports forward part of commit df09680626 ("soc/amd/picasso: Add
support for 64bit builds") to the newer AMD SoCs.

Use -Wl instead of -l to get the output format that the commands in the
Makefile expect to extract the value for PSP_BIOSBIN_SIZE. Without this
change, readelf will split the output into two lines in case of a 64 bit
coreboot build. This results in invalid amdcompress and amdfwtool
command lines which will cause the amdfwtool call to fail with

Error: BIOS binary destination and uncompressed size are required

With the old readelf -l command we get this output in a 64 bit build:

Program Headers:
  Type           Offset             VirtAddr           PhysAddr
                 FileSiz            MemSiz              Flags  Align
  LOAD           0x0000000000000080 0x0000000002030000 0x0000000002030000
                 0x0000000000010000 0x0000000000010000  RWE    0x10

while we get the correct output in a 32 bit build:

Program Headers:
  Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
  LOAD           0x000060 0x02030000 0x02030000 0x10000 0x10000 RWE 0x20

With readelf -Wl we also get the expected output in a 64 bit build:

Program Headers:
  Type           Offset   VirtAddr           PhysAddr           FileSiz  MemSiz   Flg Align
  LOAD           0x000080 0x0000000002030000 0x0000000002030000 0x010000 0x010000 RWE 0x10

TEST=This fixes the 64 bit build on Cezanne with some follow-up patches
applied.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I35f9feda4d0da3546592dfac233ca66732bd5464
Reviewed-on: https://review.coreboot.org/c/coreboot/+/69895
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Fred Reitberger <reitbergerfred@gmail.com>
2022-11-23 19:43:46 +00:00
..
acpi src/acpi: Remove unnecessary space after casts 2022-11-22 13:48:23 +00:00
arch src/arch: Remove unnecessary space after casts 2022-11-22 13:46:47 +00:00
commonlib src/commonlib: Remove unnecessary space after casts 2022-11-22 13:47:15 +00:00
console console/post.c: Sort includes 2022-10-27 15:46:39 +00:00
cpu cpu/intel/car: Define post codes 2022-11-23 03:47:18 +00:00
device src/device/pci_: Remove unnecessary space after casts 2022-11-22 13:41:26 +00:00
drivers src/drivers: Remove unnecessary space after casts 2022-11-22 13:40:56 +00:00
ec ec: Add SPDX license headers to Makefiles 2022-11-22 12:43:11 +00:00
include cpu/intel/car: Define post codes 2022-11-23 03:47:18 +00:00
lib lib/malloc.c: Fix log messages 2022-11-18 16:02:28 +00:00
mainboard Revert "mb/google/brya/var/kano: select SOC_INTEL_RAPTORLAKE" 2022-11-23 19:33:49 +00:00
northbridge src/northbridge: Remove unnecessary space after casts 2022-11-22 13:46:09 +00:00
sbom
security security: Remove unnecessary space after casts 2022-11-22 12:55:26 +00:00
soc soc/amd/*/Makefile: fix readelf parameters to get bootblock size 2022-11-23 19:43:46 +00:00
southbridge sb/intel/i82801gx/lpc.c: Use post_code() 2022-11-23 15:24:03 +00:00
superio src/superio: Remove unnecessary space after casts 2022-11-21 15:03:50 +00:00
vendorcode vc/amd/fsp/glinda/platform_descriptors.h: Update for glinda 2022-11-19 02:47:48 +00:00
Kconfig build: List all Kconfigs in CBFS config file, compress it 2022-11-18 17:19:44 +00:00