Skip to content

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

Open
quatrixone wants to merge 2 commits into
derekross:mainfrom
quatrixone:dipper-safety-entry
Open

quatrixone wants to merge 2 commits into
derekross:mainfrom
quatrixone:dipper-safety-entry

Conversation

@quatrixone

Copy link
Copy Markdown

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.

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