Skip to content

Commit b13e64d

Browse files
xhackerustcpalmer-dabbelt
authored andcommitted
riscv: vmlinux.lds.S: explicitly catch .riscv.attributes sections
When enabling linker orphan section warning, I got warnings similar as below: riscv64-linux-gnu-ld: warning: orphan section `.riscv.attributes' from `init/main.o' being placed in section `.riscv.attributes' While I don't see any usage of .riscv.attributes sections' in kernel now, just catch the sections so that we can enable linker orphan section warning. Signed-off-by: Jisheng Zhang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Palmer Dabbelt <[email protected]>
1 parent e597319 commit b13e64d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

arch/riscv/kernel/vmlinux.lds.S

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,7 @@ SECTIONS
146146
STABS_DEBUG
147147
DWARF_DEBUG
148148
ELF_DETAILS
149+
.riscv.attributes 0 : { *(.riscv.attributes) }
149150

150151
DISCARDS
151152
}

0 commit comments

Comments
 (0)