]> git.baikalelectronics.ru Git - kernel.git/commitdiff
Makefile.debug: re-enable debug info for .S files
authorNick Desaulniers <ndesaulniers@google.com>
Mon, 24 Oct 2022 20:34:14 +0000 (13:34 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 29 Oct 2022 08:20:36 +0000 (10:20 +0200)
This is _not_ an upstream commit and just for 5.4.y only. It is based
on commit 12318a273e26cad42f55c212307161fd4efd7924 upstream.

Alexey reported that the fraction of unknown filename instances in
kallsyms grew from ~0.3% to ~10% recently; Bill and Greg tracked it down
to assembler defined symbols, which regressed as a result of:

commit e0cefb2767ed ("Kbuild: do not emit debug info for assembly with LLVM_IAS=1")

In that commit, I allude to restoring debug info for assembler defined
symbols in a follow up patch, but it seems I forgot to do so in

commit 299822f98e1a ("Kbuild: make DWARF version a choice")

Fixes: e0cefb2767ed ("Kbuild: do not emit debug info for assembly with LLVM_IAS=1")
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Makefile

index 813d17bd45861797790548aaf88738416a8ed08b..d5e86096bcd8e588fa172eaeff2a96d90e6378ab 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -802,7 +802,9 @@ DEBUG_CFLAGS        += -gsplit-dwarf
 else
 DEBUG_CFLAGS   += -g
 endif
-ifneq ($(LLVM_IAS),1)
+ifeq ($(LLVM_IAS),1)
+KBUILD_AFLAGS  += -g
+else
 KBUILD_AFLAGS  += -Wa,-gdwarf-2
 endif
 endif