Skip to content

CONTRIBUTING: add Dipper single-slot recovery entry - #499

Merged
derekross merged 6 commits into
derekross:mainfrom
quatrixone:dipper-safety-entry
Nov 10, 2026
Merged

derekross merged 6 commits into
derekross:mainfrom
quatrixone:dipper-safety-entry

Conversation

@quatrixone

Copy link
Copy Markdown
Contributor

Summary

Add Xiaomi Mi 8 (dipper) to the §3.1 single-slot device table: boot is the only boot partition the installer may write, and fastboot is reached with the phone off by holding Volume Down + Power until FASTBOOT appears.

This is a separate safety-policy change; it does not add device support or permit a flash.

Checks

  • git diff --check origin/main...HEAD — passed
  • No automated tests run; documentation only.

Name the sole boot partition the installer may write and the physical fastboot button path, as required before any single-slot port is flashed.
@derekross

Copy link
Copy Markdown
Owner

Thank you for sending the Mi 8's entry as its own pull request. That's exactly the shape the single-slot section asks for. The entry has what the rules require: the codename, the one boot partition the installer may write, and how to reach fastboot by the buttons.

Whether and when to add it is my call as maintainer, and I'd like to settle a few things first:

  • What the phone has already had written. device/dipper: record stage-0 facts and first light #330's first version shows that the diagnostic image went into the stock recovery partition from rooted Android, and that it wrote its log into logdump through a widened allowlist. That was before these rules existed, so this isn't a criticism. Before I grant the first write exception for this phone, though, I'd like device/dipper: record stage-0 facts and first light #330 to record those writes and confirm that recovery holds stock's image again, checked against your backup. I've asked for that on device/dipper: record stage-0 facts and first light #330.
  • Nothing needs the entry yet. device/dipper: add a RAM-only first-light build path #505 only RAM-boots (fastboot boot), and that isn't a flash. So there's no hurry. The entry becomes necessary with the first PR that writes boot.
  • dtbo. The Mi 8 has an 8 MiB dtbo partition, and this ABL may apply its overlays to the DTB we append. Your RAM boots worked with stock's dtbo in place, which is good news. If an install ever needs dtbo changed or erased, that's a new entry. It would help if the entry or the notes said that a mainline boot works with stock's dtbo untouched.
  • A forced restart. The entry gives the way into fastboot. §3.4 also lists, per phone, how to force a restart when the phone hangs (the Pixel 8 Pro's Power + Volume Up, for example). What does the Mi 8 need: Power held for how long? Please add it to the entry or to §3.4, so the recovery steps for a hang are complete.
  • Placement. The table now sits between "these rules replace the slot B rules above for that phone:" and the rules, so that colon introduces the table. Could it go after the list instead, with a short lead-in ("Phones with an entry:")?

The title is fine for the squash.

@derekross

Copy link
Copy Markdown
Owner

Thanks for moving the table. It now sits after the rules, with its own lead-in, which reads the way I hoped.

This stays on hold for my decision, as I said last time. Here is where the other points stand, so you know what I'm waiting for:

  • What the phone has already had written. device/dipper: record stage-0 facts and first light #330 now records the recovery and logdump writes, which is good. It doesn't yet show that recovery holds stock's image again. I need that sha256 compare before I grant this phone its first write exception. I've asked for it on device/dipper: record stage-0 facts and first light #330.
  • dtbo. device/dipper: add a RAM-only first-light build path #505's runbook now says first light ran with stock's dtbo untouched. Could the entry say it too, for example "boot only; stock's dtbo stays as it is"? Then nobody reads the entry as leaving dtbo open.
  • A forced restart. device/dipper: add a RAM-only first-light build path #505's runbook says the hold time isn't recorded and not to guess, which is the right instinct. The recovery steps are still incomplete without it, though. Please find out once, attended, what forces a restart on a hung Mi 8 (Power alone or Power + Volume Up, and for how long), and add it to the entry or to §3.4.
  • The backup. The section asks for a read-only backup of every partition except userdata and super before the first flash. Your first version's backup-stock copied 15 partitions. That list leaves out logdump, system, vendor, cache and the other GPT entries. Before the first flash, please check the backup against the phone's whole partition table: the names from /sys/class/block/*/uevent, then each one present and its checksum verified.

None of this is urgent. #505 only RAM-boots, so nothing needs the entry yet. The title is fine for the squash.

@quatrixone

quatrixone commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor Author

2026-11-09 update: the current recovery partition matches the recovery image in the checksum-verified 2026-10-29 19:01 snapshot. The historical order of that snapshot and the two diagnostic recovery writes remains unknown; #330 now records that limit.

An attended test on this Mi 8 confirmed that holding Power alone for more than 10 seconds restarts it. Volume Down + Power then entered fastboot; read-only variables confirmed product dipper and unlocked=yes. No serial is published. The restart was tested from the running system, not from a simulated kernel hang.

A private live file-level userdata archive is complete and verified. It is not a raw partition image or an atomic snapshot. The existing 15-partition stock backup is still not a whole-GPT backup; that is required before a persistent flash, which has not been attempted. The exact PR #505 RAM image has not been booted.

@derekross

Copy link
Copy Markdown
Owner

Thanks for the update, and for checking recovery. A match with the saved stock image is the answer I needed. Could you put it in the notes on #330, with which saved image you compared it with and when that copy was taken? The notes there still say it hasn't been compared, and they're the record this entry points to.

On the entry itself, nothing has changed since last time, so here is where it stands:

  • dtbo: your reply says stock's dtbo is untouched. Please say it in the entry as well, for example "boot only; stock's dtbo stays as it is".
  • Forced restart: still open, as you say. device/dipper: add a RAM-only first-light build path #505 now makes it a gate before the first RAM boot, which is right. Once you've tried it from stock, please add the buttons and the hold time here or to §3.4.
  • The backup: still the 15 partitions, as you say. That's fine while nothing is flashed. Before a first flash, it needs to cover every partition in the GPT except userdata and super. Your userdata archive is a good extra, but the rule doesn't ask for it.

This stays on hold for my decision until those are in. There's no rush: #505 only RAM-boots, so nothing needs the entry yet.

@derekross

Copy link
Copy Markdown
Owner

Thank you, both edits are in. The entry now says boot only with stock's dtbo untouched, and the new column records the forced restart you found. A column is a good place for it, since every single-slot phone will need one.

One small addition I'd like in that cell: you tried the restart under Android, which was the right first place, but not yet under our kernel. On the Pixel 8 Pro, Power alone did nothing under our kernel, so it's worth saying until a RAM boot has tried it. For example: "Hold Power alone for more than 10 seconds; observed from installed Android on 2026-11-09, not yet tried under our kernel."

The rest isn't about the text. The full backup of every partition except userdata and super is still needed before a first flash, as you say. On #330 I've asked what recovery holds now, since the snapshot it matches may be from after the diagnostic writes. Once both are settled, I'll make the decision on this entry. Nothing waits on it in the meantime: #505 only RAM-boots.

The title is fine for the squash.

@quatrixone

Copy link
Copy Markdown
Contributor Author

The follow-up is in 7e231d9d41d357c81c88a58ddb1fc504bf42c6d1.

The verified off-device backup now covers all 84 GPT partitions other than userdata (and the phone has no super); the separate userdata copy is file-level and non-atomic. The current recovery partition matches the saved 10-29 image, and its boot header decompresses to kernel 4.9.337-perf-g0b3e38ef6c40, identifying it as stock recovery. The first-light kernel was RAM-booted with fastboot boot.

The attended Power-hold result is recorded precisely: holding Power alone for more than 10 seconds from installed Android restarted back into Android on 2026-11-09. It has not been tested under the RAM kernel. I did not trigger another reboot during this session.

@quatrixone

Copy link
Copy Markdown
Contributor Author

Update: the 10-second Power hold has now also been confirmed under the Omarchy Mobile RAM kernel; it restarts into Android. The recovery table records that result, replacing the earlier “not yet tested” note. No persistent partition was written.

@derekross

Copy link
Copy Markdown
Owner

Thank you for closing every open point here: the restart is now tried under our kernel as well as from Android, the full backup of all 84 partitions is taken and checked, and recovery is shown to hold an Android recovery and not the diagnostic image.

I'm accepting the entry. It names the three things this section asks for (the codename, boot as the only partition an installer may write, and fastboot by the buttons), and you observed each of them on the phone. I'll change one cell when I merge. "Confirmed to restart into Android" is true today because boot holds Android; after a first flash the same hold restarts into our image. So it will read: "Hold Power alone for 10 seconds: the phone restarts and boots whatever boot holds (tried from Android and from our RAM kernel, 2026-11-09)."

The entry comes first, as the section says, and on its own it allows no write: bin/omamobile flash and push refuse the Mi 8's ram-only method, and its allowlist is empty. So that we agree on what comes next, this is what has to be true before any first flash. All of it follows from the rules already in this section:

  1. Published sources. Kernel [Device support request] Samsung Galaxy S22 Ultra #220 merged, and the image built from omamobile and this repository's main, with both commits in the manifest.
  2. A reviewed writer. A PR that teaches bin/omamobile flash and tools/install-phone this phone's single-slot method: serial pinned, codename typed, boot only, dry run first. Until then, no fastboot flash by hand, please.
  3. The guard check on that image: device/dipper: add a RAM-only first-light build path #505's step 4, with UFS_RW still empty.
  4. The way back, written down and proven without writing. The notes say, button by button, how to put the backup's boot.img back, naming it by sha256; and that same file has been started once with fastboot boot and reached Android.
  5. A fresh backup right before the flash. Yours was taken before the restart test that booted Android again, and Android rewrites the modem's partitions, so the checksums need to be taken again after the last Android boot.
  6. No restart loop. The RAM probe reboots 20 s after it finds no USB host. Flashed, that would restart into the same image for ever, so the descriptor and plan need to say what a flashed image does instead (stay up with the screen lit, or reboot to the bootloader).
  7. Fastboot from our image by the buttons, tried once from the RAM kernel: Power for 10 seconds, then Volume Down as it restarts.
  8. The exact image RAM-booted first, attended, with the same sha256.
  9. userdata stays as it is for the first flash, with the root over NFS. Writing it erases the Android on the phone, and that's a separate decision for you to make explicitly.

None of this needs another change to this PR.

@derekross
derekross merged commit 64fdd41 into derekross:main Nov 10, 2026
2 checks passed
robertzas pushed a commit to robertzas/omarchy-mobile that referenced this pull request Nov 14, 2026
…oss#499)

* CONTRIBUTING: add Dipper single-slot recovery entry

Name the sole boot partition the installer may write and the physical fastboot button path, as required before any single-slot port is flashed.

* CONTRIBUTING: group single-slot recovery entries

* CONTRIBUTING: record Dipper forced restart

* CONTRIBUTING: identify Dipper restart test context

* CONTRIBUTING: record Dipper power-hold outcome

* CONTRIBUTING: confirm Dipper restart under RAM kernel
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants