Skip to content
/ linux Public

Commit aba5b98

Browse files
rxrblnSasha Levin
authored andcommitted
modpost: Amend ppc64 save/restfpr symnames for -Os build
[ Upstream commit 3cd9763 ] Building a size optimized ppc64 kernel (-Os), gcc emits more FP save/restore symbols, that the linker generates on demand into the .sfpr section. Explicitly allow-list those in scripts/mod/modpost.c, too. They are needed for the amdgpu in-kernel floating point support. MODPOST Module.symvers ERROR: modpost: "_restfpr_20" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_restfpr_26" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_restfpr_22" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_savegpr1_27" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_savegpr1_25" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_restfpr_28" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_savegpr1_29" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_savefpr_20" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_savefpr_22" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: modpost: "_restfpr_15" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! WARNING: modpost: suppressed 56 unresolved symbol warnings because there were too many) Signed-off-by: René Rebe <rene@exactco.de> Link: https://patch.msgid.link/20251123.131330.407910684435629198.rene@exactco.de Signed-off-by: Nathan Chancellor <nathan@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent cafea2a commit aba5b98

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

scripts/mod/modpost.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -602,6 +602,10 @@ static int ignore_undef_symbol(struct elf_info *info, const char *symname)
602602
/* Special register function linked on all modules during final link of .ko */
603603
if (strstarts(symname, "_restgpr0_") ||
604604
strstarts(symname, "_savegpr0_") ||
605+
strstarts(symname, "_restgpr1_") ||
606+
strstarts(symname, "_savegpr1_") ||
607+
strstarts(symname, "_restfpr_") ||
608+
strstarts(symname, "_savefpr_") ||
605609
strstarts(symname, "_restvr_") ||
606610
strstarts(symname, "_savevr_") ||
607611
strcmp(symname, ".TOC.") == 0)

0 commit comments

Comments
 (0)