mirror of
https://github.com/apache/nuttx.git
synced 2026-10-07 22:35:22 +00:00
libs/libc/machine/x86_64: accept R_X86_64_NONE relocations
Since the ELF linker script keeps .eh_frame, a relocatable --gc-sections link leaves R_X86_64_NONE relocations for collected functions. The loader rejected them, so no kernel-mode program could be loaded on x86_64. Assisted-by: Claude:claude-opus-5.5 Signed-off-by: raiden00pl <raiden00@railab.me>
This commit is contained in:
parent
adffae71df
commit
04c7eb43e8
1 changed files with 2 additions and 0 deletions
|
|
@ -153,6 +153,8 @@ int up_relocateadd(const Elf64_Rela *rel, const Elf64_Sym *sym,
|
|||
|
||||
switch (relotype)
|
||||
{
|
||||
case R_X86_64_NONE:
|
||||
break;
|
||||
case R_X86_64_64: /* S + A */
|
||||
*(uint64_t *)addr = sym->st_value + rel->r_addend;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue