Re: [PATCH 10/12] efi/libstub: Remove obsolete .note.gnu.property workaround
"Ard Biesheuvel" <[email protected]>
| Newsgroups | org.kernel.vger.live-patching,org.infradead.lists.linux-arm-kernel,org.kernel.vger.linux-kernel,org.kernel.vger.linux-toolchains |
|---|---|
| Message-ID | <[email protected]> |
On Mon, 17 Aug 2026, at 22:54, Nick Desaulniers wrote: > On Fri, Aug 14, 2026 at 9:45 PM Josh Poimboeuf <[email protected]> wrote: >> >> Commit e2179a09ab08 ("efi/libstub: Disable -mbranch-protection") added >> --remove-section=.note.gnu.property to the stub objcopy invocation to >> work around a Clang bug where the note was emitted for code-less object >> files even with -mbranch-protection=none. >> >> That was fixed by LLVM commit a48f6079f288 ("[AArch64] Generate >> .note.gnu.property based on module flags") which was released with >> Clang 12. The minimum Clang version is now Clang 17, so this workaround >> is no longer needed. >> >> On arm64, the stub also no longer builds with -mbranch-protection=none, >> as it has inherited the kernel's flags since commit 8358098b9787 >> ("arm64: efi: Enable BTI codegen and add PE/COFF annotation"). >> >> Remove the workaround. This fixes BTI on arm64, and is a no-op on >> RISC-V and LoongArch where the vmlinux generic NOTES macro discards it, >> and the x86 and ARM decompressors discard .note.* explicitly. >> >> Signed-off-by: Josh Poimboeuf <[email protected]> >> --- >> drivers/firmware/efi/libstub/Makefile | 6 ------ >> 1 file changed, 6 deletions(-) >> > > I verified the above all looks correct. Thanks for the cleanup. > Reviewed-by: Nick Desaulniers <[email protected]> > Thanks. I've cherry-picked just this patch for v7.3