OpenVZ / Virtuozzo kernel development (devel@openvz.org)
 help / color / mirror / Atom feed
From: Konstantin Khorenko <khorenko@virtuozzo.com>
To: Eva Kurchatova <eva.kurchatova@virtuozzo.com>
Cc: devel@openvz.org
Subject: [Devel] [PATCH hci-8.1 v2 4/6] configs: build the User Mode Linux KUnit kernel without debug info
Date: Mon, 26 Oct 2026 23:34:22 +0100	[thread overview]
Message-ID: <20261026-b4-prep-khorenko-vstor-143636-uml-config-v2-4-76c8329592af@virtuozzo.com> (raw)
In-Reply-To: <20261026-b4-prep-khorenko-vstor-143636-uml-config-v2-0-76c8329592af@virtuozzo.com>

kernel.spec strips the UML binary and deletes the debug info it
extracts, as for the selftests. Every build generated DWARF and BTF for
the whole image only to throw them away.

Nothing that reads a run needs them:

- WARN and BUG reports carry file:line (DEBUG_BUGVERBOSE)
- UBSAN reports carry file:line of the check
- KASAN reports and stack traces name the functions through kallsyms

For line numbers in a KASAN stack, rebuild the same source with debug
info: the config is in the binary (IKCONFIG), and gcc generates the
same code with and without -g. BTF has no user at all, nothing runs
BPF in the UML kernel.

https://virtuozzo.atlassian.net/browse/VSTOR-143636

Feature: KUnit tests on User Mode Linux
Signed-off-by: Konstantin Khorenko <khorenko@virtuozzo.com>
---
 redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO             | 1 +
 .../generic/um/CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT                 | 1 +
 redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_NONE        | 1 +
 3 files changed, 3 insertions(+)

diff --git a/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO b/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO
new file mode 100644
index 0000000000000..ba6c41346853e
--- /dev/null
+++ b/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO
@@ -0,0 +1 @@
+# CONFIG_DEBUG_INFO is not set
diff --git a/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT b/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT
new file mode 100644
index 0000000000000..62eed21ca3053
--- /dev/null
+++ b/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT
@@ -0,0 +1 @@
+# CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT is not set
diff --git a/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_NONE b/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_NONE
new file mode 100644
index 0000000000000..e37e387af671b
--- /dev/null
+++ b/redhat/configs/custom-overrides/generic/um/CONFIG_DEBUG_INFO_NONE
@@ -0,0 +1 @@
+CONFIG_DEBUG_INFO_NONE=y

-- 
2.43.0

_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

  parent reply	other threads:[~2026-10-26 22:35 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-26 22:34 [Devel] [PATCH hci-8.1 v2 0/6] configs: a User Mode Linux kernel for the KUnit tests Konstantin Khorenko
2026-10-26 22:34 ` [Devel] [PATCH hci-8.1 v2 1/6] configs: add a User Mode Linux config " Konstantin Khorenko
2026-10-26 22:34 ` [Devel] [PATCH hci-8.1 v2 2/6] kasan: let a config leave the KUnit test out under KUNIT_ALL_TESTS Konstantin Khorenko
2026-10-26 22:34 ` [Devel] [PATCH hci-8.1 v2 3/6] configs: build the User Mode Linux KUnit kernel with KASAN Konstantin Khorenko
2026-10-26 22:34 ` Konstantin Khorenko [this message]
2026-10-26 22:34 ` [Devel] [PATCH hci-8.1 v2 5/6] configs: turn off module-only subsystems in the User Mode Linux config Konstantin Khorenko
2026-10-26 22:34 ` [Devel] [PATCH hci-8.1 v2 6/6] configs: check the User Mode Linux KUnit config at build time Konstantin Khorenko
     [not found] ` <0429d3d2-4664-4afa-a088-993344b6140f@virtuozzo.com>
2026-10-27 10:42   ` [Devel] [PATCH hci-8.1 v2 0/6] configs: a User Mode Linux kernel for the KUnit tests Konstantin Khorenko
2026-10-27 10:51 ` Konstantin Khorenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261026-b4-prep-khorenko-vstor-143636-uml-config-v2-4-76c8329592af@virtuozzo.com \
    --to=khorenko@virtuozzo.com \
    --cc=devel@openvz.org \
    --cc=eva.kurchatova@virtuozzo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox