Item 3: fold the debug kernel into the closing build

kas/forgefirm-glowforge-debug.yml builds one dev image on the debug
kernel (FORGEFIRM_KERNEL_DEBUG=1, tagged dev-debug) beside the closing
release and dev images; the debug options never touch either.
scripts/bench/debug_kernel_drills.py runs the two drills (three
load/unload cycles under DEBUG_MUTEXES, a forced -EPROBE_DEFER unwind),
each read against dmesg for lock splats, refusing on a non-debug kernel
or a non-idle machine; it is registered as a board bench tool. BRINGUP
item 3 names the mechanism and stays remaining work (run it on the
closing burn); the site's Build page documents the variant.
This commit is contained in:
ScottW514
2026-08-31 15:54:28 -04:00
parent 8ba998c3ef
commit 298abf8a12
4 changed files with 230 additions and 7 deletions
+32
View File
@@ -0,0 +1,32 @@
# ============================================================================
# ForgeFIRM — debug-kernel build variant
# ============================================================================
# One target: a dev image whose kernel carries the lock-correctness options
# (DEBUG_MUTEXES, PROVE_LOCKING, DEBUG_ATOMIC_SLEEP, DEBUG_SPINLOCK). It rides
# the closing build: after the normal release + dev images build, one pass of
# this config produces a dev image tagged "(dev-debug)". The bench boots it
# once to run the module load/unload and forced -EPROBE_DEFER drills
# (forgefirm/scripts/bench/debug_kernel_drills.py), then the real image is
# flashed. The options never touch a release or a normal dev build.
#
# cd forgefirm
# kas build kas/forgefirm-glowforge-debug.yml
#
# The debug kernel has a different config signature, so bitbake rebuilds the
# kernel and the dev image under it without disturbing the images already in
# build/tmp/deploy/images/glowforge/; the debug dev image lands beside them
# with its own DATETIME stamp and the "(dev-debug)" version string.
# ============================================================================
header:
version: 14
includes:
- forgefirm-glowforge.yml
target: forgefirm-image-dev
local_conf_header:
debug-kernel: |
FORGEFIRM_KERNEL_DEBUG = "1"
FORGEFIRM_VERSION_STRING:pn-forgefirm-image-dev = "${DATETIME} (dev-debug)"
FORGEFIRM_VERSION_STRING[vardepsexclude] += "DATETIME"