Fix mmc1 microSD initialization with sdhci-msm HPM/LPM regulator_set_load

- Update drivers/mmc/host/sdhci-msm.c in patch 0012 so
  sdhci_msm_register_vreg(), sdhci_msm_set_vmmc(), msm_toggle_vqmmc(),
  and sdhci_msm_runtime_resume() vote 200 mA vmmc / 20 mA vqmmc HPM
  loads during probe, card init, and UHS-I tuning while
  sdhci_msm_runtime_suspend() drops vmmc/vqmmc to 2 mA / 0 mA LPM
- Rebuild vmlinuz/modules/DTBs via scripts/build-kernel-audio.sh and
  sync prebuilt/ and overlay/rootfs/ artifacts
- Guard sdhci-msm regulator_set_load hunks in scripts/check-rebuild.sh,
  document the fix in BATTERY-OPTIMIZATION-ANALYSIS.md, AGENTS.md, and
  Unreleased CHANGELOG.md notes, and update rebuilt --mkinitfs image
  SHA-256 checksums across all four targets (verified live on Nokia 2720)
This commit is contained in:
Luxferre committed 2026-11-21 12:48:05 +02:00
1 parent c9eb28b891
commit 601aaca25c
9 files changed
+26739 -26707

No files matched your search

+13 -9
View File
@@ -564,15 +564,15 @@ fi
echo "[check] Known-good flashable image set..."
for pair in \
"7ed88928baf8f8926e7213919e304991cd0a30e0166c0b91da610396f606cf37 images/bananarchy-nokia-argon.img" \
"616ef7ceaa3e49b73ff90f14c8d30e658f3e35349549414a78c1f6a15e6f75c2 images/bananarchy-nokia-beatles.img" \
"a51cf223d3b6231e1a00947f5a084939c54c76d10051a43d37dfd2652d88f99f images/boot-bananarchy-nokia-beatles.img" \
"beb3c4f9d4bbf2356e6d106fa10adec105f34d3f696bfce8109c85869bab5bfd images/bananarchy-nokia-argon.img" \
"a240e3d243c9bef0fc1c014f113b0d14d7295815ff3681e7887d4650ebd7f18a images/bananarchy-nokia-beatles.img" \
"c92f99bc07348f9cd63f083440116fdd7fc219c5cbe20526d6eb3cd134cbd7ca images/boot-bananarchy-nokia-beatles.img" \
"f13db705a714aaebd2d8fcc2e0f7266d0e40268c0a276208117dfdf9d8f45351 images/boot-lk2nd-nokia-beatles-display.img" \
"598482a219e235cc323821d8dda5c62d380ec6773b739fdf1c12cf8ad7c6648e images/bananarchy-nokia-coconut.img" \
"f6ba9567d9f57a5503751c023a606eae71a8f68047c03380f68ab488b8ab51b5 images/boot-bananarchy-nokia-coconut.img" \
"e58abff5555b13f2896962166aa2469772ea00f2bf396d032f3637072262a055 images/bananarchy-nokia-coconut.img" \
"e96ea67004bc37f4ad912c5cbcc00fc4ad6da895e31bb5201395910c067174e8 images/boot-bananarchy-nokia-coconut.img" \
"9a5bd2da6cfd95c745d9c1acb2e3bc61afa339824810e3d160bf079e17b23192 images/boot-lk2nd-nokia-coconut-display.img" \
"d86779df5f38d0d5cd516b9123f17dfbd7ba8874435517146e281382e5998f9a images/bananarchy-nokia-sparkler.img" \
"1e6a1659c4ae9a95c29c96a41edf9343535229d583dcec3d2063667c98745fbc images/boot-bananarchy-nokia-sparkler.img" \
"a96454fa5baa41e9c5c510636c2a3ac070d01914941b786f05c2e653f9aa8c30 images/bananarchy-nokia-sparkler.img" \
"f8fb959bb945b04a3cf9081aed191f055c3650cad8c6ec6509bd0a8694aaf529 images/boot-bananarchy-nokia-sparkler.img" \
"120ade81bc5416263a1afd95a29981675358b98516e105e5ed611edf258a29f7 images/boot-lk2nd-nokia-sparkler-display.img"; do
set -- $pair
want=$1
@@ -2448,8 +2448,12 @@ fi
echo "[check] 72-hour standby battery optimizations (patch 0012, codec analog, DTS set-load, policy)..."
if [ ! -f "$BASE_DIR/patches/kernel/0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch" ] || \
! grep -qF '0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch' "$BASE_DIR/scripts/build-kernel-audio.sh"; then
fail "kernel patch 0012 or its build-kernel-audio.sh wiring is missing"
! grep -qF '0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch' "$BASE_DIR/scripts/build-kernel-audio.sh" || \
! grep -qF 'mmc->ios.vdd ? 200000 : 0' "$BASE_DIR/patches/kernel/0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch" || \
! grep -qF 'regulator_set_load(msm_host->mmc->supply.vmmc, 200000)' "$BASE_DIR/patches/kernel/0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch" || \
! grep -qF 'regulator_set_load(mmc->supply.vqmmc, 20000)' "$BASE_DIR/patches/kernel/0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch" || \
! grep -qF 'regulator_set_load(host->mmc->supply.vmmc, 2000)' "$BASE_DIR/patches/kernel/0012-msm8909-standby-wifi-wcd-panel-ldo-bms.patch"; then
fail "kernel patch 0012, sdhci-msm HPM/LPM regulator_set_load hunks, or build-kernel-audio.sh wiring is missing"
fi
for ko in "$BASE_DIR/prebuilt/kernel-6.12.1-msm8916/codecs/snd-soc-msm8916-analog.ko.zst" \
"$BASE_DIR/overlay/rootfs/lib/modules/6.12.1-msm8916/kernel/sound/soc/codecs/snd-soc-msm8916-analog.ko.zst"; do