Skip to content

nvme: apple: drop the post-M4 adoption - #40

Draft
DjDeveloperr wants to merge 1 commit into
fix/nvme-apple-t8140-ans-restartfrom
fix/nvme-apple-drop-post-m4-adopt
Draft

DjDeveloperr wants to merge 1 commit into
fix/nvme-apple-t8140-ans-restartfrom
fix/nvme-apple-drop-post-m4-adopt

Conversation

@DjDeveloperr

@DjDeveloperr DjDeveloperr commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Held. Don't merge until the distributions make uboot-aurora require an aura with aurora-silicon/aura#107, until #38's start from off passes on the Neo (it failed through ANS-chain-kit-08), and until #38 has run on an M4 Mac. The merge order of this and the distribution PRs is the owner's call.

This sits on #38 (base fix/nvme-apple-t8140-ans-restart), so the diff here is only the removal.

With aura#107, aura powers a post-M4 ANS off after its own use and passes the SART entries on. After that, only an older aura hands U-Boot a running post-M4 session. This drops apple_nvme_adopt(). A running session that an earlier stage set up now fails the probe with:

ANS was handed over running; this U-Boot needs an aura that powers ANS off after use (aura#107) and passes apple,sart-entries

A mismatched pair then says what's wrong instead of booting without NVMe and no reason given. iBoot's own session, which no stage has set up, still gets its one-time RTKit handshake. Pre-M4 doesn't change.

On an older aura this U-Boot has no NVMe. That is why it waits for the distribution pins (aurora-silicon/alarm-aurora#174, aurora-silicon/fedora-aurora#213, aurora-silicon/nixos-aurora#178). The compatibility matrix is in #38.

Size

+8/-61, one file. The second push only put braces on every branch of the probe's if chain.

Tested

  • apple_m1 with WERROR builds clean with gcc 16.1.1 (0 warnings). The build guest verified clean before and after. checkpatch has nothing on the diff.
  • Row loud of ANS-chain-kit-04 passed on the Neo (J700) on 2026-11-08. The Neo's installed Stage 1 (an older aura) handed its session on running, and this U-Boot printed the message above 22 s into the boot and failed the probe with -19. No hang: it went on to boot the kernel from RAM, without NVMe. The kit's image is 3934c16f2b, which differs from this head only in those braces.
  • Row chain, the start from off this needs, hasn't passed yet: in kit-04 aura failed before U-Boot, in kits 05 to 07 U-Boot nvme: apple: start a post-M4 ANS the boot loader powered off #38's start of ANS failed. kit-08 showed ANS's CPU keeping its idle state through aura's power-off; that is still open.
  • This head (0ac2fb7698) is the same removal rebased onto nvme: apple: start a post-M4 ANS the boot loader powered off #38's 66b55b3783. apple_m1 with WERROR builds clean (0 warnings).

🤖 Generated with Claude Code

With aura powering ANS off after its own use and passing the SART
entries on, nothing hands U-Boot a running post-M4 session any more but
an older aura. Adopting one as it runs is gone. Such a session fails the
probe with a message that names the aura U-Boot needs, so a mismatched
pair says what is wrong instead of booting without NVMe silently.

Hold this until the distributions make uboot-aurora require a matching
aura: on an older aura U-Boot has no NVMe.

Signed-off-by: Diljit Singh <[email protected]>
@RyanTheTide

Copy link
Copy Markdown
Contributor

Blockers: 2.

  1. The base no longer matches the tree this would land in. nvme: apple: start a post-M4 ANS the boot loader powered off #38 is CONFLICTING with aurora-wip, and aurora-wip has since gained the T8140/T8142 binding (nvme: apple: bind the T8140 and T8142 controllers #47, 73f9ffb) and the ESP pick on every Apple NVMe controller (apple: pick the ESP on every Apple NVMe controller #50, 5445237). On aurora-wip the post-M4 probe has only the wake and adopt paths (drivers/nvme/nvme_apple.c:870-873 at aurora-wip). The J813 boot reported in nvme: apple: bind the T8140 and T8142 controllers #47, which the fedora-aurora uboot bump relies on, goes through one of those two. This PR turns the adopt branch into a hard -ENODEV (drivers/nvme/nvme_apple.c:867-870 at this head). So once it is restacked, any post-M4 Mac whose earlier stage still hands ANS on running (the Neo row here shows that case) loses its disk in U-Boot and cannot reach GRUB. Also, aura main has since merged "nvme: don't report a session off before handing it on live" (aura#412) and has open work for a stopped or live handoff (aura#380, aura#403). That suggests the stages may keep handing ANS on rather than always powering it off. Restack on aurora-wip after nvme: apple: start a post-M4 ANS the boot loader powered off #38 is reworked. Before the adopt path goes, confirm against current aura main that no shipped stage still hands a running session to U-Boot. If that cannot be confirmed, close this.
  2. nvme_apple.c:869: the runtime message names a pull-request number ("aura#107"). aura#107 is closed: its commits landed through aura#144. The message should name what the user can check, i.e. the aura release or version that powers ANS off and passes apple,sart-entries.

HW row: on aurora-wip + #38 + this, with current aura main Stage 2: start from off on a J700, a J813 and one M4 (J713 or J773g), 5 cold boots each: NVMe binds, the Aurora ESP is picked, GRUB starts. Then one boot on each with the previous released Stage 2 to show the -ENODEV message and no hang.

Assisted-by: LLM (Claude:Opus 5.5)

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