Single M0 kernel batch with CONFIG_SUSPEND off #17

Merged
noah merged 8 commits from rb/w04-kernel-options into rebuild 2026-10-09 20:08:37 -06:00
Owner

What

The single M0 kernel batch for the rebuild (rebuild M0, kernel lane), now with CONFIG_SUSPEND off.

  • cgroup v2 controllers (memcg, pids, cpu with CFS bandwidth), namespaces, PSI, /proc/config.gz
  • raw table and the CT target (flare-edge#537), the owner match, the cgroup match, CONNMARK
  • the nftables set (N-40) and the Buildroot nftables patch so socket cgroupv2 matches on a 32-bit kernel (flare-edge#591)
  • build/required-symbols.txt as the single source of record, read by build-kernel.sh; WARDEN_CONFIG_ONLY=1 for a seconds-long symbol gate
  • the clk_core_mcu_rtc keep-alive flag, in the patch and in the documented source
  • QEMU kernel-contract check at boot and a staged-script entry (warden.run)
  • new in this round: # CONFIG_SUSPEND is not set (Noah, 2026-10-09). PM_SLEEP, SUSPEND_FREEZER, FREEZER, FW_CACHE, HOTPLUG_CPU, KEXEC and CRASH_DUMP follow. The AIC8800 modules build and carry vermagic 6.18.46.

Checks run

  • tests/required-symbols/run-required-symbols-tests.sh: all pass, including the new no-suspend checks (proven red when the defconfig loses the explicit unset)
  • config-only expansion with the packaging toolchain: 49 required and 2 probe assertions verified
  • full SDK kernel build with WARDEN_MODULES_COLLECT="drivers/net/wireless/aic8800 drivers/net/usb": zImage 8,970,752 B (the previous batch kernel was 9,069,056 B), six modules with vermagic 6.18.46

Base: rebuild (equal to flare-edge-next at d22c900). The flare-edge pin bump follows in its own PR.

Generated with Claude Code

https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk

## What The single M0 kernel batch for the rebuild (rebuild M0, kernel lane), now with CONFIG_SUSPEND off. - cgroup v2 controllers (memcg, pids, cpu with CFS bandwidth), namespaces, PSI, `/proc/config.gz` - raw table and the CT target (flare-edge#537), the owner match, the cgroup match, CONNMARK - the nftables set (N-40) and the Buildroot `nftables` patch so `socket cgroupv2` matches on a 32-bit kernel (flare-edge#591) - `build/required-symbols.txt` as the single source of record, read by `build-kernel.sh`; `WARDEN_CONFIG_ONLY=1` for a seconds-long symbol gate - the `clk_core_mcu_rtc` keep-alive flag, in the patch and in the documented source - QEMU kernel-contract check at boot and a staged-script entry (`warden.run`) - new in this round: `# CONFIG_SUSPEND is not set` (Noah, 2026-10-09). PM_SLEEP, SUSPEND_FREEZER, FREEZER, FW_CACHE, HOTPLUG_CPU, KEXEC and CRASH_DUMP follow. The AIC8800 modules build and carry vermagic 6.18.46. ## Checks run - `tests/required-symbols/run-required-symbols-tests.sh`: all pass, including the new no-suspend checks (proven red when the defconfig loses the explicit unset) - config-only expansion with the packaging toolchain: 49 required and 2 probe assertions verified - full SDK kernel build with `WARDEN_MODULES_COLLECT="drivers/net/wireless/aic8800 drivers/net/usb"`: zImage 8,970,752 B (the previous batch kernel was 9,069,056 B), six modules with vermagic 6.18.46 Base: `rebuild` (equal to `flare-edge-next` at d22c900). The flare-edge pin bump follows in its own PR. Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
noah added 5 commits 2026-10-09 18:40:01 -06:00
kernel: single M0 batch (cgroups, namespaces, PSI, raw table, nftables) with a symbol list and clock keep-alive
ci / test (push) Successful in 18s
ci / mcdc (push) Successful in 19s
ci / bench (push) Successful in 9s
ci / qemu-tools (push) Successful in 53s
ci / prune-artifacts (push) Skipped
ci / quality (push) Successful in 46s
ci / badges (push) Skipped
ci / kernel-symbols (push) Successful in 1m25s
ci / patches-apply (push) Successful in 21s
ci / kernel-build (push) Skipped
0360b8dc46
One kernel flash for everything later work needs (rebuild M0, d09 M0-2):

- warden_defconfig: cgroup v2 controllers (MEMCG, CGROUP_PIDS, CGROUP_SCHED,
  FAIR_GROUP_SCHED, CFS_BANDWIDTH), the byte-metering match symbols
  (XT_MATCH_CGROUP, XT_CONNMARK, XT_MARK, IP6_NF_MANGLE), IKCONFIG and
  IKCONFIG_PROC, XT_MATCH_OWNER, the raw tables and the CT target (the
  NOTRACK for flare-edge#537), NAMESPACES with its five sub-options
  (USER_NS stays closed at boot by a sysctl), PSI, and the nftables set
  (NF_TABLES, ip and ip6 families, NFT_CT, NFT_MASQ, NFT_NAT, NFT_LIMIT,
  NFT_SOCKET, NFT_REJECT). TIME_NS and RT_GROUP_SCHED are explicitly unset.
  HW_RANDOM_ROCKCHIP is built in as a probe for the hardware RNG.
- build/required-symbols.txt and probe-symbols.txt are the source of record;
  build-kernel.sh asserts both against the final .config instead of a
  hand-written list (olddefconfig drops an unknown or unsatisfied symbol
  without a word).
- WARDEN_CONFIG_ONLY=1 stops after that assertion (a seconds-long CI gate) and,
  like a full build, writes the final .config and its sha256 (CONFIG_OUT),
  the digest firmware images record as KCONFIG_SHA256.
- clk_core_mcu_rtc gets CLK_IGNORE_UNUSED like clk_core_mcu, in the patch and in
  the enablement source it documents, so 6.18 keeps the HPMCU mtime clock up.
- CI: a kernel-symbols job expands the real configuration and asserts the lists
  on every push; offline tests prove the assertion fires for every failure shape.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
qemu: check the kernel contract at boot and run a staged script (warden.run)
ci / test (push) Canceled after 0s
ci / mcdc (push) Canceled after 0s
ci / bench (push) Canceled after 0s
ci / qemu-tools (push) Canceled after 0s
ci / kernel-symbols (push) Canceled after 0s
ci / patches-apply (push) Canceled after 0s
ci / prune-artifacts (push) Canceled after 0s
ci / kernel-build (push) Canceled after 0s
ci / quality (push) Canceled after 0s
ci / badges (push) Canceled after 0s
445b2082f5
init verifies build/required-symbols.txt against the guest's /proc/config.gz,
the cgroup v2 controllers and PSI and prints markers; boot-smoke.sh fails when a
marker is missing. mkinitramfs.sh stages the list and merges EXTRA_DIR; run.sh
--append passes warden.run=<path>, which init runs before powering off (used by the
flare-edge M0 limit tests). README notes the symbol lists.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
buildroot: patch nftables so socket cgroupv2 matches on 32-bit kernels
ci / test (push) Canceled after 0s
ci / mcdc (push) Canceled after 0s
ci / bench (push) Canceled after 0s
ci / qemu-tools (push) Canceled after 0s
ci / kernel-symbols (push) Canceled after 0s
ci / patches-apply (push) Canceled after 0s
ci / prune-artifacts (push) Canceled after 0s
ci / kernel-build (push) Canceled after 0s
ci / quality (push) Canceled after 0s
ci / badges (push) Canceled after 0s
aa6956f595
nftables 1.1.0 builds the id of "socket cgroupv2 level N <path>" from st_ino, which
is the 64-bit kernfs id only on 64-bit kernels. On armv7 the id is
(generation << 32) | ino and st_ino carries the low half, so the rule loaded and
never matched: byte metering per service counted nothing (found by the M0 counting
test in QEMU on the 6.18.46 kernel). The patch takes the id from the directory's file
handle, in both the parse and the listing path.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
buildroot: nftables cgroupv2 patch reads the handle with the raw syscall (uClibc has no wrapper)
ci / test (push) Successful in 19s
ci / mcdc (push) Successful in 18s
ci / bench (push) Successful in 5s
ci / qemu-tools (push) Failing after 13s
ci / kernel-symbols (push) Successful in 1m24s
ci / prune-artifacts (push) Skipped
ci / kernel-build (push) Skipped
ci / badges (push) Skipped
ci / patches-apply (push) Successful in 17s
ci / quality (push) Successful in 1m2s
469f31c278
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
kernel: turn CONFIG_SUSPEND off (rebuild M0)
ci / test (pull_request) Canceled after 0s
ci / prune-artifacts (push) Canceled after 0s
ci / bench (pull_request) Canceled after 0s
ci / kernel-build (push) Canceled after 0s
ci / qemu-tools (pull_request) Canceled after 0s
ci / quality (push) Canceled after 0s
ci / badges (push) Canceled after 0s
ci / quality (pull_request) Canceled after 0s
ci / test (push) Canceled after 0s
ci / bench (push) Canceled after 0s
ci / qemu-tools (push) Canceled after 0s
ci / kernel-symbols (push) Canceled after 0s
ci / patches-apply (push) Canceled after 0s
ci / mcdc (pull_request) Canceled after 0s
ci / kernel-symbols (pull_request) Canceled after 0s
ci / patches-apply (pull_request) Canceled after 0s
ci / prune-artifacts (pull_request) Canceled after 0s
ci / kernel-build (pull_request) Canceled after 0s
ci / badges (pull_request) Canceled after 0s
ci / mcdc (push) Canceled after 0s
8615f7c13a
The panel is wall powered and never sleeps the SoC. SUSPEND defaults to y, so the
defconfig carries an explicit unset, and required-symbols.txt asserts SUSPEND and
PM_SLEEP unset against the final .config. Kconfig then drops PM_SLEEP, PM_SLEEP_SMP,
SUSPEND_FREEZER, FREEZER, PM_GENERIC_DOMAINS_SLEEP, FW_CACHE and VT_CONSOLE_SLEEP; as
PM_SLEEP_SMP was the only thing selecting HOTPLUG_CPU on this one-core SoC, HOTPLUG_CPU,
KEXEC and CRASH_DUMP go with it. PM, PM_CLK and runtime PM stay.

Regression test: tests/required-symbols asserts both lines, refuses a config that turns
either back on, and fails when the defconfig loses the explicit unset (proven red).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
noah added 1 commit 2026-10-09 18:42:15 -06:00
qemu init: read the command line without for-in-cat (blueflare/bfe-core1106-sdk#18)
ci / test (push) Canceled after 0s
ci / mcdc (push) Canceled after 0s
ci / bench (push) Canceled after 0s
ci / bench (pull_request) Canceled after 0s
ci / qemu-tools (pull_request) Canceled after 0s
ci / quality (push) Canceled after 0s
ci / kernel-symbols (pull_request) Canceled after 0s
ci / badges (push) Canceled after 0s
ci / prune-artifacts (pull_request) Canceled after 0s
ci / badges (pull_request) Canceled after 0s
ci / qemu-tools (push) Canceled after 0s
ci / kernel-symbols (push) Canceled after 0s
ci / test (pull_request) Canceled after 0s
ci / patches-apply (push) Canceled after 0s
ci / mcdc (pull_request) Canceled after 0s
ci / prune-artifacts (push) Canceled after 0s
ci / kernel-build (push) Canceled after 0s
ci / patches-apply (pull_request) Canceled after 0s
ci / kernel-build (pull_request) Canceled after 0s
ci / quality (pull_request) Canceled after 0s
0589829619
shellcheck 0.9 in the qemu-tools CI job reports SC2013 for
`for w in $(cat /proc/cmdline)` and exits non-zero, which kept CI red on the M0 kernel
branch since the warden.run entry was added. Read /proc/cmdline into a variable and loop
over its words.

Regression test: tests/qemu-init/run-init-shellcheck-tests.sh (run by the qemu-tools job)
shellchecks the rootfs scripts and proves the old form red on a doctored copy.

Fixes #18.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
noah added 2 commits 2026-10-09 19:17:59 -06:00
DRM_MSM_VALIDATE_XML depended on `$(PYTHON3) -c "import lxml"`, so the expanded .config gained a
line on hosts where python3 could import lxml and the whole-file digest differed (the flashed image
ec276f77 against e8e9ef1c from a config-only run on the same tree). Drop the unused Qualcomm symbol
with a one-block Kconfig patch; the digest is now ec276f77 everywhere and equals the flashed one.

Regression test: tests/required-symbols/run-config-determinism-tests.sh runs the config-only
expansion with a python3 whose import lxml works and one where it fails and requires the same
digest; it is proven red on a copy of the tree without the patch. The kernel-symbols CI job runs it.

Fixes #19.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
kernel: probe V3 passed, the hardware RNG symbols are required
ci / qemu-tools (pull_request) Successful in 50s
ci / patches-apply (pull_request) Successful in 26s
ci / mcdc (push) Successful in 18s
ci / patches-apply (push) Successful in 24s
ci / test (push) Successful in 11s
ci / bench (push) Successful in 8s
ci / qemu-tools (push) Successful in 50s
ci / prune-artifacts (push) Skipped
ci / kernel-build (push) Skipped
ci / kernel-symbols (push) Successful in 2m21s
ci / test (pull_request) Successful in 12s
ci / quality (push) Successful in 33s
ci / badges (push) Skipped
ci / mcdc (pull_request) Successful in 17s
ci / bench (pull_request) Successful in 7s
ci / prune-artifacts (pull_request) Skipped
ci / kernel-build (pull_request) Skipped
ci / quality (pull_request) Successful in 34s
ci / badges (pull_request) Skipped
ci / kernel-symbols (pull_request) Successful in 2m20s
35dc64714e
Probe V3 (d09 T14, AT-M0-33) on the bench panel with the batch kernel: /dev/hwrng from the
rockchip-rng driver, a 2.6 MB read in 2.4 s (1058 KiB/s) without blocking, and 1 FIPS 140-2 failure
in 1000 blocks (limit 3). CONFIG_HW_RANDOM and CONFIG_HW_RANDOM_ROCKCHIP move from probe-symbols.txt
to required-symbols.txt; the probe list is now empty, which build-kernel.sh accepts (it skips an
empty probe list; the required list may never be empty). The config does not change: the defconfig
already built both in, and the digest stays ec276f77.

Regression tests (run-required-symbols-tests.sh): both symbols asserted and built in, a config
without either is refused by name, the probe list may be empty.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Cxh2piVufTWbzKTmUafTkk
noah merged commit 5507842878 into rebuild 2026-10-09 20:08:37 -06:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: blueflare/bfe-core1106-sdk#17