aboutsummaryrefslogtreecommitdiff
path: root/tools/lib/bpf/bpf_prog_linfo.c
diff options
context:
space:
mode:
authorArvind Sankar <[email protected]>2020-05-11 18:58:49 -0400
committerArd Biesheuvel <[email protected]>2020-05-14 11:11:20 +0200
commite78d334a5470ead861590ec83158f3b17bd6c807 (patch)
tree588a4e9347d8c6f9e9b0a2662e3e20cb40235963 /tools/lib/bpf/bpf_prog_linfo.c
parent3d8c11efd528d56972d44ed0de51c4e11a9a4fa9 (diff)
x86/boot: Mark global variables as static
Mike Lothian reports that after commit 964124a97b97 ("efi/x86: Remove extra headroom for setup block") gcc 10.1.0 fails with HOSTCC arch/x86/boot/tools/build /usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld: error: linker defined: multiple definition of '_end' /usr/lib/gcc/x86_64-pc-linux-gnu/10.1.0/../../../../x86_64-pc-linux-gnu/bin/ld: /tmp/ccEkW0jM.o: previous definition here collect2: error: ld returned 1 exit status make[1]: *** [scripts/Makefile.host:103: arch/x86/boot/tools/build] Error 1 make: *** [arch/x86/Makefile:303: bzImage] Error 2 The issue is with the _end variable that was added, to hold the end of the compressed kernel from zoffsets.h (ZO__end). The name clashes with the linker-defined _end symbol that indicates the end of the build program itself. Even when there is no compile-time error, this causes build to use memory past the end of its .bss section. To solve this, mark _end as static, and for symmetry, mark the rest of the variables that keep track of symbols from the compressed kernel as static as well. Fixes: 964124a97b97 ("efi/x86: Remove extra headroom for setup block") Reported-by: Mike Lothian <[email protected]> Tested-by: Mike Lothian <[email protected]> Signed-off-by: Arvind Sankar <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Ard Biesheuvel <[email protected]>
Diffstat (limited to 'tools/lib/bpf/bpf_prog_linfo.c')
0 files changed, 0 insertions, 0 deletions