Repository navigation
omamobile-device-tegu: the 9a's modem start skips where it can't run, and the record of it running by itself (opt-in kept; stacked on #372) - #590
Conversation
…ot, opt-in The 9a's modem only started by hand, from a bring-up script outside the package. omamobile-tegu-modem-up is now packaged: the kernel's own CP drivers when it has them, else the bring-up modules; the NV check, then a sleep inhibitor, then the drivers; a latch written before the drivers and cleared at CP ONLINE, so a start that never got there stops later boots until a human looks; the once-per-boot refusal; and with --phone the phone service and, when installed, the Phone and Messages bridge. omamobile-tegu-modem-boot.service runs it at boot, installed but never enabled by the package. A scratch-root test covers the driver choice, the order, the latch and the refusals.
… CP drivers load
The profile's check also wants CPIF's ports, so before the drivers it refused ("the CPIF port is not loaded") and the first boot start on the palmtop failed there. It runs after the drivers again, as the bring-up script had it; the inhibitor and the latch still come before any driver.
…dem latch until a clean shutdown, and the 9a's screen-on at start The latch was cleared as soon as the CP reached ONLINE, so a hang or reset after that would have started the modem again at every boot. It now stays until the modem profile's unit stops cleanly at shutdown (an ExecStopPost that runs only when the unit's result is success), and the next boot refuses while it's there, as TELEPHONY-PLAN 2.4 plans. The start also refuses a pcie_gs201_cp already loaded without allow_hw, as omamobile-modem-start does, and waits with wait-online instead of reading the state once a second. The screen-on that makes the 9a's modem send signal reports is now set only by tegu's sitd drop-in (OMAMOBILE_SIT_SCREEN_ON_AT_START), so the 7 Pro's start-up is unchanged; derekross#381 already decodes the reports. The README and the boot unit give the order, the preconditions (slot B marked successful, a kernel with linux-omarchy-mobile#172, the charger for the first boots) and the rollback; the test checks the latch is on disk before any driver loads, that it stays past ONLINE, and the allow_hw refusal.
… says the modem starts The boot unit's 300 s timeout could run out while the start waited for sitd to register, and the bridge would never start. The start now queues sitd and the bridge (ordered after sitd) without waiting. The 9a's DEVICES cell no longer says the package doesn't start the modem: its opt-in boot unit does.
… the next boot its modem reboot-to (and so bin/omamobile push) skips the clean stop that removes the latch, so the next boot refused the modem as if the last one had hung (derekross#390). The latch now names its boot and records ONLINE, and a latch from a boot that reached ONLINE and ended with reboot-to (its note, derekross#403) is cleared with the note. A start that never reached ONLINE, or a note for another boot, still refuses.
…y's Location switch omamobile-gnss serves fixes only when the modem profile runs gnssd (OMAMOBILE_MODEM_GNSS=1), and the boot start didn't ask for it, so every Location request found no gnssd and the service hit its start limit. The boot unit now runs omamobile-tegu-modem-up --phone --gnss. The daily kernel keeps the PERIC0 GPIO bus clock critical, as linux-omarchy-mobile#172 does, so the modem's GNSS traffic can't hang the palmtop.
Two reboots on the palmtop with the boot unit enabled, the NV check, the UFS count after a shutdown with the CP up and a phone-smoke report, as Derek asked before the README tells anyone to enable it.
…s again The status words added in derekross#360 left each item's old sentence hanging after them. Each item now says what derekross#372 does and what is still the target, in whole sentences.
The profile unit's ExecStopPost removed the latch only when SERVICE_RESULT was success, and at a shutdown it never is: the CP's power-off in ExecStop ends rfsd or cbd before systemd's SIGINT, so the profile's supervisor exits 1. On the palmtop on 2026-11-03 a systemctl reboot with the modem up left the latch, and the next boot refused the modem. ExecStopPost now runs omamobile-tegu-modem-up --stopped, which removes this boot's latch once the start reached ONLINE, whatever the result, as omamobile-modem-start --stopped does on the Pixel 7 Pro. A hang or a reset never reaches it, so those still refuse the next boot.
…SS testing until the default, the latch's stop as it is now DEVICES reserves works for on by default, and the boot unit is opt-in, so Modem and GNSS read testing until the follow-up that turns it on after kernel derekross#187. The latch is described as removed by the profile unit's stop at shutdown, the README gives the unit's --phone --gnss and says the reboot-to path is under test, and section 2.7 records the reboot that left the latch and the re-run on the fixed script.
…k and the reboot-to path passed (2.7) The radio backup check after the day's reboots read every NV partition the same, and a reboot-to with the CP ONLINE cleared its latch and brought the modem back on its own at the next boot.
… the latch too The script's header, the comment above systemd-run, the last "modem OK" message and 2.7 step 3's Expect still said only the profile's stop at shutdown removes the latch; since the note commit, the next boot after a reboot-to clears it as well. Step 6 now records that the UFS and CP shutdown are not observable after a reboot-to, and that its reboot-to was derekross#403's, built by hand.
… the next boot its modem
The starter kept any leftover latch and refused every later start until a
human removed it. That is right for a bring-up that never reached ONLINE
(a hang in the bring-up itself must not repeat on its own), but a boot
that ended with the modem up and no clean stop had a working bring-up: on
2026-11-08 a held power key ended such a boot on the 9a ("Long Press
Power Key Reboot (PMIC COLD)" in the bootloader's console record), and
the three boots after it came up without the modem, two of them clean
reboots, until the latch was removed by hand.
Now a latch from another boot that reads ONLINE is moved aside as
modem-bringup-started.unclean-<time> and the start goes on. A second
unclean end in a row, with that copy still there, holds as before: a
phone that resets with the modem up every time must not start it in a
loop (CONTRIBUTING.md 3.4; the Pixel 7 Pro's modem-up marker refuses once
and holds at the second). The profile's clean stop (--stopped) removes the
copies with the latch. A latch without ONLINE still holds from the first
time, and reboot-to's note is handled as before.
test/modem-up covers the three cases (one unclean end starts, two hold,
no ONLINE holds), the note naming another boot now ending in a start, and
--stopped removing the copies.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01176vSgL9PRmxFqbaB3D9vk
(cherry picked from commit 8c6dc50)
…only on a witnessed clean stop of the modem The 9a's latch was removed by the profile unit's ExecStopPost whatever the stop's result, so a stop that timed out or failed counted as clean, and the next boot started the CP with no evidence that its last instance had stopped. Now the profile's ExecStop (omamobile-modem's profile_stop) writes a stop intent for a unit invocation whose main process still runs with result success, powers the CP off, and once the boot device itself has reported OFFLINE writes the invocation's ID to /run/omamobile-modem/stop-<invocation>, the witness; a failed power-off fails the stop and leaves none. rfsd's job, which the power-off ends, holds itself open while the intent is in place, so systemd's SIGINT finds the supervisor and a clean stop ends in success for the first time (every shutdown read exit-code before). omamobile-modem-cp power-off no longer takes a missing boot device for OFFLINE. The starter records the profile unit's invocation in the latch at ONLINE, and --stopped removes the latch only for that invocation, with its witness and result success; it refuses to load anything when the installed omamobile-modem lacks the contract file (modem/stop-witness-version, 1). The reboot-to note still clears the latch: a deliberate restart isn't the reset loop the latch guards against. The 7 Pro's omamobile-modem-start --stopped is unchanged; the witness is there for it to use. Also: modem-sit 0.3.33, which the rebase onto main had left at main's version.
…p 7) Three rounds on the palmtop: the witnessed stop passed (the first shutdown with the CP up to end in success), then two watchdog resets with the modem up, traced to the owner's sleep-test kernel lacking kernel derekross#172's PERIC0 gate fix and kernel derekross#150's SPI flush order. The latch behaved as designed through both: kept after the reset, moved aside once, held after the second.
…m fixes passed With the PERIC0 gate critical and the SPI flush order in the kernel, the modem ran 4.5 minutes from the boot unit without a reset, and its witnessed stop ended in success and removed the latch.
…he unit's business, and the retry costs an ABL try The profile comment no longer claims every clean stop reads success: the 9a's transient unit does, and the 7 Pro's service is derekross#532's question. The README's rollback says to disable the unit after the first reset on a 9a whose slot B isn't marked, since the retry would spend a second ABL try.
… modem stack on by default The boot unit gets a vendor wants link, as the 7 Pro's target did in derekross#398, and conditions that skip it on a phone without the provisioning files or without CP drivers (the device tree's cpif node or the bring-up modules), so a boot that can't run it costs nothing. The README says what it costs and needs and how to turn it off (mask), the test holds the link and the conditions, the 9a's Modem and GNSS cells read works, and TELEPHONY-PLAN 2.8 is the gated runbook for enabling it on the palmtop.
|
Thank you, @W4HO-ham. The change itself is neat: one link, conditions that I can't take it as "on by default" yet, though, for two reasons.
What I'd suggest: keep #372 as the opt-in unit; bring the in-tree path (the For the order: this sits on #372, which is waiting for my 7 Pro run of the |
…stays opt-in; its skip conditions, and the record of it running by itself The vendor wants link is gone again: marking slot B on the 9a is on hold and the unit can't tell whether B is marked, so the owner still turns the start on. What stays is the conditions that skip an enabled unit on a phone without the provisioning files or CP drivers. The unit, the README and DEVICES no longer say the published device tree has a cpif node: it comes from the device's modem-cpif overlay. The Modem and GNSS cells read testing, with what ran. TELEPHONY-PLAN keeps 2.8 as the record of the unit running by itself and adds 2.9, the starter's in-tree branch on the published kernel.
|
Agreed on both points, and thank you for checking the tree rather than my sentence: there is no
What's kept from the original: the skip conditions, since an owner who enables the unit on an unprovisioned phone should get a skip, not a failure. On the slot mark: nothing to add from here except that the palmtop is one more 9a to try #484's guard and the rebased #483 on when you want a second device after your 7 Pro run. |
…l stops confirmed
|
Thank you. This is the change I asked for and more: the link is gone and the test holds the package to opt-in, the text says where the Three corrections to the record before I merge, all small:
Order: #594 first (your README points at its |
…rnal, 42 of 43 stops in the cell, and what the in-tree start needs Three times in 2.9 were wrong (the fifth in-tree boot, the texts' boot and the repeat of the unconfirmed stop, which came nineteen minutes later, not an hour). The section now has a table of the evening's boots with the modem up, taken from journalctl --list-boots and each boot's own lines: when it started, on which kernel, who started the modem, and whether its stop was confirmed. The Modem cell says 42 of 43 stops confirmed with one unexplained, and names derekross#274 next to the overlay as what the in-tree start needs; the GNSS cell says the 9a's GNSS nodes are merged. 2.9's heading no longer calls its kernel the published one.
|
All three are in (3c0102f).
The order is fine with me, and I'll rebase this once #372 is squashed. |
|
A correction to my last comment: "the 39 unit-started stops" should read 37. That is the table's seven plus the loop's thirty; I haven't re-read how the four earlier stops of 11-08 and 11-09 were started, so I shouldn't have counted them either way. |
Main took 0.1.17 (derekross#568) and 0.3.33 (derekross#569) for other changes and omamobile-device-tegu 0.2.11 (derekross#591), so this branch's packages move to the next numbers and the README names the modem package version the stop command comes with.
|
Main with #372 squashed is merged in ( #409 and #403 had the same kind of conflict and are merged up too: #409 in the 9a row of DEVICES.md (main's row with its Suspend cell), #403 in the version files (omamobile-device-tegu 0.2.14 and omamobile-modem 0.1.19 there, one above main). |
|
Thank you. All three corrections are what I asked for, and the table of the evening's boots is better than what I asked for: with the start, the kernel, who started the modem and the stop for each one, the one unconfirmed stop now sits in a record I can reason from, and your note that it and its clean repeat were the two hand starts is a useful lead. Thank you too for correcting the count in your own comment. I checked the merge of main: the diff is only your eight files, nothing of #372's or main's was lost, and the unit is still opt-in with the test holding it there (your last comment says "on by default", which I take as a slip). One small thing is left, and it is only timing: #274 was merged a few minutes before your push, so the Modem and GNSS cells in DEVICES call it "in review" and warn about a kernel without the PHY's driver that main no longer builds. Once #594 is in, its "in review" will be stale as well. After I merge #594, could you push one change to the two cells so they say the in-tree start needs the overlay and the two config lines, all merged, and drop the "without #274" clause? Versions: #594 goes first and takes device-tegu 0.2.14, so this one becomes 0.2.15; I'll set it at merge. That also matters for your palmtop: it runs a 0.2.14 you built with the wants link, and it needs a higher published number to pick up the package without the link. |
|
Yes, "on by default" was a slip in my comment: the unit stays opt-in here, and the test holds it there. #409 and #601 touched the same row of DEVICES, so I merged main in again (the row is main's with this PR's two cells). When #594 is in I'll push the one change you describe: the Modem and GNSS cells say the in-tree start needs the overlay and the two config lines, all merged, without the "without #274" clause, and section P's sentence about #274 goes with it. |
…ig lines are merged derekross#274 (the PCIe PHY's config line) and derekross#594 (the modem-cpif overlay and the GNSS link driver's config line) are in, so the 9a's Modem and GNSS cells no longer call them "in review" or warn about a tree build without the PHY's driver, and section P says a kernel built from the tree now has everything the in-tree start needs. omamobile-device-tegu 0.2.15, one above main.
…ves them Kernel derekross#237's review asked for the two pins' CON, PUD and DRV, since the tree's GNSS nodes give them no pin group. Read on 2026-11-10 with no GNSS driver loaded, one controller per read: gpa5-4 is an input with stock's pull-down, gpp2-3 an input with a pull-down where stock has an output without one.
|
Thank you. The pins paragraph in CI is green on this head, which already contains today's main, and the package's tests and On the number: #654 also says 0.2.15, and it names that number in its MODEM-PLAN sentence, so I'll merge #654 as 0.2.15 and this one as 0.2.16. Nothing for you to change. One thing for the palmtop: you wrote on #654 that it now runs a hand-built 0.2.17, so neither published package will replace it by itself. Once both are in, please install |
The commits under this pull request's own are on main now in their merged form (derekross#356 to derekross#372, derekross#590), so the result is today's main plus this pull request's own commits, replayed on it; only version files conflicted, and they keep main's numbers.
The commits under this pull request's own are on main now in their merged form (derekross#356 to derekross#372, derekross#590), so the result is today's main plus this pull request's own commits, replayed on it; only version files conflicted, and they keep main's numbers.
The commits under this pull request's own are on main now in their merged form (derekross#356 to derekross#372, derekross#590), so the result is today's main plus this pull request's own commits, replayed on it; only version files conflicted, and they keep main's numbers.
The commits under this pull request's own are on main now in their merged form (derekross#356 to derekross#372, derekross#590), so the result is today's main plus this pull request's own commits, replayed on it; only version files conflicted, and they keep main's numbers.
…ins come from (#679) The two stock values the 2026-11-10 pin readings are compared with now name their source: `gnss_spi_irq` (gpa5-4) and `gnss_spi_int` (gpp2-3) in Google's `zuma-cp-s5400-phone-gnss.dtsi`, linked at the commit FAR-ALIVE-PLAN cites. This was the one point left open when #590 merged. Checked against the file at that commit, and against Google's tegu board files for an override (none).
…art is skipped where it can't run, and the record of it running by itself (derekross#590) The opt-in boot unit gets conditions that skip it, not fail it, on a phone without the provisioned files or CP drivers, and the starter loads the PCIe PHY's driver itself and refuses before the latch on a kernel without it. The unit stays opt-in while marking slot B on the 9a is on hold. TELEPHONY-PLAN 2.8 and 2.9 record the unit running by itself (42 of 43 stops confirmed, one unexplained) and the in-tree drivers through the starter; DEVICES and MODEM-PLAN say the overlay and the two config lines are merged.
…ins come from (derekross#679) The two stock values the 2026-11-10 pin readings are compared with now name their source: `gnss_spi_irq` (gpa5-4) and `gnss_spi_int` (gpp2-3) in Google's `zuma-cp-s5400-phone-gnss.dtsi`, linked at the commit FAR-ALIVE-PLAN cites. This was the one point left open when derekross#590 merged. Checked against the file at that commit, and against Google's tegu board files for an override (none).
Stacked on #372. Was "on by default"; after the review it keeps the start opt-in and brings what is left: the conditions that skip the unit where it can't run, the corrected text, and the record of the unit running by itself.
What changes on top of #372
omamobile-tegu-modem-boot.servicegets conditions that skip it, not fail it, when the owner has enabled it on a phone that can't run it: without the modem chroot, the NV checksums or the board properties (tools/phone-provisionputs all three there), or without CP drivers (the device tree'scpifnode, or the owner's bring-up modules). The package test holds them.cpifnode. It comes from the device'smodem-cpifoverlay, device/tegu, omamobile-device-tegu: the Pixel 9a's modem and GNSS from the published kernel's own drivers #594.What turning it on needs later: the slot B decision, and #594 merged. Then it is the wants link and three lines of test.
tools/pr-checkand the package'stest/allpass.