Fix unbootable image: restore kernel/module ABI compatibility

The previous battery pass rebuilt the kernel image from a retuned config and
produced an image stuck on the lk2nd logo. Two incompatibilities with the
linux-postmarketos-qcom-msm8916 module tree (which this repo does not rebuild)
were identified:

1. Vermagic: CONFIG_PREEMPT_VOLUNTARY removes CONFIG_PREEMPT_BUILD, so the
   rebuilt kernel reported "6.12.1-msm8916 SMP mod_unload ARMv7 p2v8" while
   every package module reports "6.12.1-msm8916 SMP preempt mod_unload ARMv7
   p2v8". modprobe refuses all of them, including panel-mipi-dbi, so the
   display never initialises.
2. Struct layout: CONFIG_SUSPEND selects CONFIG_PM_SLEEP, which adds fields to
   struct dev_pm_info. Modules built without it use wrong dev->power offsets,
   so matching vermagic alone is not enough.

Restored the known-good kernel config, the serial-console cmdline and the DTB
wakeup-source additions. The kernel image is still cross-compiled by
build-kernel-audio.sh but from the original config, so vermagic and struct
layouts match every module in the rootfs. Reverted the config-level items K1,
K6, K7, K8, K13 and K14; implementing them requires vendoring and rebuilding
the entire pmaports kernel module tree.

Kept: K2 clock-latency-ns, K3/K4/K5 via patch 0006 (rebuilt with the original
config), K10 IPv6 sysctl, and all U1-U14 userspace changes.

Rebuilt the kernel image/modules/DTBs and images/bananarchy-nokia-argon.img
with --mkinitfs. Verified: all modules (package + rebuilt) now report identical
vermagic, boot.img contains the new zImage + DTB byte-for-byte, the console
cmdline is restored, check-rebuild.sh passes and artifact drift is 0.

Docs: CHANGELOG.md (recovery section), MANUAL.md, README.md, AGENTS.md,
BATTERY-OPTIMIZATION-ANALYSIS.md (section 11).
This commit is contained in:
Bantam committed 2026-11-07 17:32:03 +02:00
1 parent ad3461babf
commit 0dbb37fba3
127 files changed
+190712 -136883

No files matched your search

+2 -3
View File
@@ -1,3 +1,2 @@
# Bananarchy: no earlycon / serial console. Keeping ttyMSM0 as a
# console holds the UART clock on and generates printk wakeups.
# A debug build may re-add: earlycon console=ttyMSM0,115200
earlycon
console=ttyMSM0,115200
Binary file not shown.
@@ -1939,8 +1939,6 @@
remoteproc@a21b000 {
compatible = "qcom,pronto-v3-pil", "qcom,pronto";
/* Allow the WCNSS/pronto remoteproc to wake the AP from suspend. */
wakeup-source;
reg = <0xa204000 0x2000 0xa202000 0x1000 0xa21b000 0x3000>;
reg-names = "ccu", "dxe", "pmu";
memory-region = <0x74>;