diff options
| author | Heinrich Schuchardt <[email protected]> | 2023-10-24 08:30:47 +0200 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2023-11-02 22:38:01 -0400 |
| commit | be6a249b417fb159db6fc3f4b7d72eb2fd036554 (patch) | |
| tree | 273285cfbf999e57ac8a402c5ce0e43373156de9 /arch/sandbox/cpu | |
| parent | a4ed4c8a51435a63ca79e6d7bca317eff30e9ed3 (diff) | |
sandbox: eliminate unused functions from binaries
The sandbox should closely mimic other architectures.
Place each function or data in a separate section and let the linker
eliminate unused ones. This will reduce the binary size.
In the linker script mark that u_boot_sandbox_getopt are to be kept.
Signed-off-by: Heinrich Schuchardt <[email protected]>
Reviewed-by: Tom Rini <[email protected]>
Diffstat (limited to 'arch/sandbox/cpu')
| -rw-r--r-- | arch/sandbox/cpu/u-boot.lds | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/sandbox/cpu/u-boot.lds b/arch/sandbox/cpu/u-boot.lds index ba8dee50c7b..52f13af3742 100644 --- a/arch/sandbox/cpu/u-boot.lds +++ b/arch/sandbox/cpu/u-boot.lds @@ -15,7 +15,7 @@ SECTIONS _u_boot_sandbox_getopt : { *(_u_boot_sandbox_getopt_start) - *(_u_boot_sandbox_getopt) + KEEP(*(_u_boot_sandbox_getopt)) *(_u_boot_sandbox_getopt_end) } |
