Skip to content

[Intel Mac P10] Order T2 Bluetooth startup after BCM4377 Wi-Fi readiness - #4

Open
iJustinCabral wants to merge 3 commits into
andrew-boyd:intel-mac/p10-broadcom-wififrom
iJustinCabral:intel-mac/p10/t2-bluetooth-startup
Open

iJustinCabral wants to merge 3 commits into
andrew-boyd:intel-mac/p10-broadcom-wififrom
iJustinCabral:intel-mac/p10/t2-bluetooth-startup

Conversation

@iJustinCabral

@iJustinCabral iJustinCabral commented Sep 28, 2026 •

Copy link
Copy Markdown

Follow-up to [Intel Mac P10] Consolidate Broadcom calibration and sleep recovery (omacom#12688). Part of the Intel Mac series.

Depends on #1 (P03 module-list preservation). Without it, a repeat hardware setup pass rewrites t2.conf and this gate's receipt reports a changed owned file.

Problem

On MacBookAir9,1, loading hci_bcm4377 before the BCM4377 Wi-Fi function has initialized its firmware leaves Bluetooth unreliable.

Change

  • A transactional installer (omarchy setup t2-bluetooth, fresh hardware leaf, migration) blacklists early HCI loading and installs bluetooth-after-wifi.service. The service waits up to 25 s for the firmware-backed Wi-Fi netdev, then loads Bluetooth before BlueZ and user sessions. A receipt records exact bytes and modes, so --verify and --rollback work and administrator edits are never overwritten.
  • Robustness change in this revision: the gate and eligibility check no longer assume Wi-Fi is at PCI 0000:73:00.0. They find the single 14e4:4488 function by ID on every poll, and no match or an ambiguous match times out safely as before. Model and T2 guards are unchanged. A test enforces that the gate's readiness logic still matches the hardware-qualified gate apart from the kernel pin and this discovery.
  • Upgrade path: installed gates are recorded byte-for-byte and a different revision is refused. The previous helper is therefore recognized by SHA-256 and replaced in place, rollback still restores the pre-install state, and failed or interrupted upgrades are handled. Migration 1790562468 runs a new upgrade action that leaves absent or rolled-back gates alone.

Validation

29 unit tests (17 before), including discovery at other addresses, ambiguous devices, and upgrade success, failure, interruption and refusal. The new tests fail on the previous code. Read-only checks on the live MacBookAir9,1 found the Wi-Fi function and its ready interface, and its installed helper matches the recognized previous hash.

Hardware: on MacBookAir9,1, the Bluetooth icon, toggle, AirPods reconnect and audio were verified with this startup ordering, and the PCI-discovery eligibility in this revision passed read-only live checks on the same machine.

🤖 Generated with Claude Code

iJustinCabral and others added 3 commits September 23, 2026 13:47
MacBookAir9,1 brings the controller up before combo firmware is ready,
so BlueZ reports powered with an empty class. Gate module load and
desktop startup on Wi-Fi readiness.

Follow-up to intel-mac/p10-broadcom-wifi. Taken from
fix-t2-vintage-mac-support at 3063fa2.
The gate and eligibility check waited for Wi-Fi at the fixed PCI address
0000:73:00.0, so a different bus enumeration would leave Bluetooth
unloaded for that boot. Discover the single 14e4:4488 function on every
poll, keeping the MacBookAir9,1 and T2 guards.

Installed gates record the helper's exact bytes and refuse a different
revision, so recognize the previous helper by SHA-256 and replace it in
place with rollback preserved. A migration upgrades installed gates only,
leaving absent or rolled-back setups alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.

1 participant