2
0
Fork 0
mirror of https://github.com/AsahiLinux/u-boot synced 2024-12-29 06:23:07 +00:00
u-boot/arch/sandbox/lib/sections.c
Andrew Scull aac53d3d96 sandbox: Rename EFI runtime sections
Rename the sections used for placing the EFI runtime so that they don't
start with a '.'. ELF says that sections starting with a '.' are
reserved for system use, but the sandbox runs as a normal user process
so should be using user sections instead.

Clang's ASAN adds redzones to non-user sections and the extra padding
meant that the list of options was being corrupted. Naming the sections
as user sections avoids this issue as clang handles them as we intended.

Signed-off-by: Andrew Scull <ascull@google.com>
2022-06-23 12:58:18 -04:00

13 lines
405 B
C

// SPDX-License-Identifier: GPL-2.0+
/*
* Copyright 2013 Albert ARIBAUD <albert.u.boot@aribaud.net>
*
*/
#include <linux/compiler.h>
char __efi_runtime_start[0] __section("___efi_runtime_start");
char __efi_runtime_stop[0] __section("___efi_runtime_stop");
char __efi_runtime_rel_start[0]
__section("___efi_runtime_rel_start");
char __efi_runtime_rel_stop[0]
__section("___efi_runtime_rel_stop");