[RFC PATCH 0/1] zboot: Garbage collect unused functions
From: Alexandre Ghiti
Date: Wed Jun 21 2023 - 07:44:47 EST
This patch is meant to solve the issue reported by lkp in [1] with the KASLR
series support for RISC-V.
The problem in [1] is caused by the addition of new functions in
efi-stub-helper.c which reference symbols that are not defined in the context
of zboot. Those functions are not used in zboot but it causes those link
errors.
I can move those new functions around so that the problem disappears, but I
believe that fixing that using the linker garbage collection is more sane.
That's an RFC, I'll include it in my KASLR series if that's the right
direction.
[1] https://lore.kernel.org/oe-kbuild-all/202306080741.ArdxyO6n-lkp@xxxxxxxxx/
Alexandre Ghiti (1):
libstub: zboot: Use -ffunction-sections + --gc-sections
drivers/firmware/efi/libstub/Makefile | 1 +
drivers/firmware/efi/libstub/Makefile.zboot | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
--
2.39.2