Skip to content

Fix WPA3 on BCM4364 T2 Macs - #9803

Open
kazeshini178 wants to merge 2 commits into
omacom:quattrofrom
kazeshini178:fix/macbookpro16-wpa3
Open

kazeshini178 wants to merge 2 commits into
omacom:quattrofrom
kazeshini178:fix/macbookpro16-wpa3

Conversation

@kazeshini178

@kazeshini178 kazeshini178 commented Sep 2, 2026 •

Copy link
Copy Markdown

Summary

  • keep brcmfmac firmware SAE offload enabled on BCM4364 (14e4:4464) T2 Macs
  • correct the feature_disable documentation: 0x80000 is SAE, not FWAUTH
  • remove the exact Omarchy-owned 0x82000 blocks from existing BCM4364 T2 installs, wherever they sit in the file, and request a reboot
  • leave other Broadcom Macs (including the T2-less BCM4364 iMac19,x) and administrator-customized configurations unchanged

Fixes #9802.

Related: #7439, #7577, #6652.

Why

BCM4364 firmware on T2 Macs (B3 on the tested 2019 16-inch MacBookPro16,1) needs its advertised SAE offload path to join WPA3-only networks. Omarchy's feature_disable=0x82000 transition-mode workaround disables bit 19 (BRCMF_FEAT_SAE) as well as firmware supplication, so WPA3-SAE authentication is unavailable on these machines.

feature_disable=0x82000 never disabled FWAUTH: it disabled FWSUP and SAE. FWAUTH is bit 20 (0x100000) and was enabled both before and after this fix. The behavioral change on BCM4364 T2 Macs is restoring FWSUP and SAE, which were verified against WPA2, transition-mode, and WPA3 networks. There is no evidence that disabling FWAUTH is needed for this client-mode issue.

With the quirk enabled, a WPA3-only connection timed out. Reloading the same driver and firmware with feature_disable=0 exposed SAE_OFFLOAD; the same NetworkManager profile then associated, obtained DHCP, and passed gateway and internet ping checks. The persistent configuration was verified after a second reload.

Scope

The exemption was originally gated on DMI product MacBookPro16,1. Following review, it is now gated on the chip: BCM4364 (14e4:4464) together with the T2 bridge (106b:180[12]). That covers every machine with hardware evidence: the MacBookPro16,1 measured here, and the MacBookPro15,2 reported in this thread and measured in #13024.

It deliberately stops there. The workaround remains useful for older Broadcom firmware with broken WPA2/WPA3 transition-mode handling, and the T2 BCM4355 (43dc) and BCM4377 (4488) Macs and the T2-less BCM4364 iMac19,x keep the quirk until someone tests them. #13024 drops the quirk on all T2 Macs. If the maintainer prefers that wider scope, this PR is the narrower option.

Test plan

  • bash test/shell.d/brcmfmac-supplicant-test.sh
  • bash test/shell.d/brcmfmac-wpa3-cleanup-test.sh, including blocks with lines after them, blocks between user lines, repeated blocks, byte-for-byte preservation of surrounding lines, reworded blocks left alone, and non-exempt hardware left alone
  • mutation checks: the previous end-of-file-only cleanup fails the new "lines after the block" case, and removing the T2 check from the cleanup gate fails the "other Broadcom Macs" case
  • ./test/cli
  • bash -n on all changed shell files
  • git diff --check
  • live WPA3-SAE/PMF-required association, DHCP, gateway ping, and internet ping on BCM4364B3
  • live WPA2/WPA3 transition AP through both WPA-PSK and SAE/PMF-required profiles, including DHCP and 0%-loss gateway/internet pings
  • disconnect/reconnect cycle on the transition AP's WPA-PSK profile

./test/all was also run. The changed Wi-Fi tests passed; five unrelated environment/baseline tests failed. Three require a separate omarchy-pkgs checkout, while launch-about-test.sh and network-qr-test.sh fail in this non-Wayland test environment. No failure references a changed file.

A separate WPA2-only AP was not available. The WPA2 authentication path itself was verified by pinning the transition AP profile to WPA-PSK; NetworkManager logged WPA-PSK WPA-PSK-SHA256 FT-PSK, and the connection passed association, DHCP, reconnect, and traffic tests.

@thedavidweng

Copy link
Copy Markdown

Can confirm this exact issue also affects MacBookPro15,2 (and many more models) and the fix will work too.

The model check product_name == "MacBookPro16,1" is too narrow:

  1. All T2 Intel Macs (MacBookPro15,x, MacBookPro16,x, MacBookAir8,x/9,x, Macmini8,1, iMac20,x, MacPro7,1) use the same BCM4364 (14e4:4464) controller and 2021-2023 modern firmware lineage that natively supports SAE offload.
  2. The original bug that inspired Apply the Broadcom Wi-Fi quirk to Macs without a T2 #6652 was on legacy pre-T2 hardware (BCM43602, 2015-era firmware). Applying the quirk to BCM4364 was an accidental overshoot.

@omarchybot

Copy link
Copy Markdown
Collaborator

Reviewed at 7f04107292aae8499fe435ad3ad1c5205c868213 against quattro. No defects found in the change itself; it now waits on a hardware confirmation and a scope decision from the maintainer.

What was checked. The mask is right: 0x82000 is bits 13 and 19, BRCMF_FEAT_FWSUP and BRCMF_FEAT_SAE, so the old comment calling 0x80000 FWAUTH was wrong and the quirk does remove SAE offload. The only Omarchy code that writes /etc/modprobe.d/brcmfmac.conf is the installer (whole file) and migrations/1786391100.sh (appended at the end), so the cleanup's two exact-match cases cover every file Omarchy itself produced, and the 2025 T2 installer's legacy block is matched as it was written in #1657. Anything else in the file is left alone, as intended.

Where it ran. On a disposable Omarchy worker: ./test/cli passed, brcmfmac-supplicant-test.sh 15/15 and brcmfmac-wpa3-cleanup-test.sh 7/7. With the installer and 1786391100.sh put back to quattro and the new migration removed, the same tests fail (a MacBookPro16,1 keeps WPA3 firmware offload), so they test the change rather than pass either way. That is stub-level evidence only: the bug is in the Wi-Fi firmware, and no worker has a BCM4364.

Second opinion. Codex Medium compared this with #13024 and #7577 and, like this review, picked this one as the fix to bring forward: it is the only one whose after-state was measured on the hardware, across WPA3-only, transition-mode PSK and SAE. It also noted that migrations/1788320383.sh removes the block only when it is the whole file or at its end, and only one copy; that is right, but neither layout is one Omarchy writes, so it is a robustness point rather than a defect here. #13024's cleanup removes every whole-line occurrence and is the stronger migration.

Competing fixes. #13024 fixes the same issue by gating on the chip instead of the model, and goes further: it drops the quirk on every T2 Mac, including BCM4355 and BCM4377 machines nobody has measured, on the argument that Arch's wpa_supplicant 2.12 carries a revert of the regression the quirk outlived. The comment above from @thedavidweng reports the same failure on a MacBookPro15,2, so a MacBookPro16,1 gate likely leaves other BCM4364 Macs with the same problem. #7577 covers Apple Silicon only and does not reach this machine.

What it waits on. The maintainer: the hardware result here comes from the pull request's own author, which cannot stand as independent confirmation, and choosing between a model gate and a chip or T2-wide gate is theirs to make.

@kazeshini178 kazeshini178 changed the title Fix WPA3 on MacBookPro16,1 Fix WPA3 on BCM4364 T2 Macs Oct 8, 2026
@kazeshini178

Copy link
Copy Markdown
Author

Thanks @thedavidweng and @omarchybot. Updated in response to both comments:

  • Scope. The exemption is now gated on BCM4364 (14e4:4464) on a T2 Mac rather than DMI product MacBookPro16,1, so the MacBookPro15,2 report is covered. It does not go further than the hardware evidence: BCM4355/BCM4377 T2 Macs and the T2-less BCM4364 iMac19,x keep the quirk. Between this PR and fix: preserve WPA3 on Broadcom BCM4364 and Apple Silicon Macs #13024, that leaves the maintainer a choice of scope: BCM4364 T2 only here, or every T2 Mac there.
  • Cleanup robustness. migrations/1788320383.sh now removes either exact Omarchy block wherever it sits on whole-line boundaries, and every copy of it. Other lines are kept byte for byte, including trailing newlines. Reworded or merged lines are still left alone. New tests cover each of these cases. The previous end-of-file-only logic fails the new tests.

Gate the WPA3 exemption on BCM4364 (14e4:4464) with a T2 bridge instead
of DMI product MacBookPro16,1, covering the reported MacBookPro15,2.

Cleanup now removes owned blocks wherever they sit on whole-line
boundaries, every copy, keeping other bytes intact.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[High risk] Modifies Wi-Fi driver configuration and adds system migration logic.

The PR appears safe to merge; no actionable issues were found.

What we checked:

  • Other Macs keep their settings: The cleanup requires both the T2 bridge and BCM4364. Other chips and T2-less BCM4364 Macs exit before the file is read or changed.
  • Failed cleanup can retry: The runner stops when the migration fails. It writes the completion marker only after the migration succeeds.

Summary

Restores firmware WPA3 support on BCM4364 T2 Macs while keeping the workaround on other Broadcom Macs.

  • Skips feature_disable=0x82000 for the affected hardware during installation and migration.
  • Removes exact historical Omarchy blocks from existing configurations and requests a reboot.
  • Adds tests for hardware scope, repeated blocks, surrounding settings, and symlinks.
  • No actionable issues found. Review checks were based on source inspection; tests were not run.
Diagram
%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Check hardware] --> B{BCM4364 and T2?}
  B -->|No| C[Keep existing workaround behavior]
  B -->|Yes| D[Skip writing the workaround]
  D --> E{Historical Omarchy block exists?}
  E -->|No| F[Leave configuration unchanged]
  E -->|Yes| G[Request reboot]
  G --> H[Remove owned blocks and keep other settings]
Loading

Reviews (1) · Last reviewed commit: "fix: exempt BCM4364 T2 Macs, harden WPA3..." · Reviewed by Greptile

@omarchybot

Copy link
Copy Markdown
Collaborator

Re-reviewed at 3de0cb8bf4d1fcc0c51c1513a174d51ed88079f5 against quattro, covering the new commit. No defects found that would affect a user. It waits on the maintainer for a hardware confirmation and the choice of scope against #13024.

What changed and what was checked. The exemption is now gated on BCM4364 (14e4:4464) together with the T2 bridge, in the installer, in migrations/1786391100.sh and in the cleanup migrations/1788320383.sh. The cleanup now removes either Omarchy-written block wherever it sits on whole lines, removes every copy, and keeps the other bytes. It reads the file with a sentinel so trailing newlines survive, and it still fails, and so gets retried, when the file can't be read. omarchy-migrate runs every pending migration whatever its number, so landing 1788320383 after later-numbered migrations is fine.

Where it ran. On a disposable Omarchy worker, ./test/cli passed, brcmfmac-supplicant-test.sh passed 15/15 and brcmfmac-wpa3-cleanup-test.sh passed 11/11. A separate stubbed reproduction ran the quattro installer and this one across six hardware combinations. On quattro, BCM4364 with a T2 gets feature_disable=0x82000. Here it does not. BCM4364 without a T2, BCM4377 and BCM4355 on a T2, BCM43602, and Apple Silicon all still get the quirk exactly as on quattro. I ran the cleanup against ten file layouts: the block alone, the 1786391100 append, the block mid-file, adjacent blocks, the block glued to a user line, a commented-out block, unrelated options only, blank lines around the block, and an unreadable file. Each did what the description says. All of this is stub-level evidence: the bug is in the Wi-Fi firmware, and no worker has a BCM4364.

Second opinion. Codex Medium also found the hardware gate correct and the change proportionate. Like this review, it picked this pull request over #13024 as the one to bring forward, since this is the older fix and it is scoped to the hardware that was measured. That agreement is not guaranteed to be independent. It also raised two points about the cleanup that I confirmed but do not count as defects:

  • The removal loop works on the edited text, not the original. So if the legacy comment line sits right before the current block, and a bare options brcmfmac feature_disable=0x82000 sits right after it, removing the current block joins those two lines into a legacy block, and that gets removed too. I reproduced this on the worker. No Omarchy path writes that layout, and the line removed is the same quirk this migration exists to take off that hardware.
  • A blank line directly before a legacy block is removed along with the block. That changes only whitespace in a modprobe file.

Competing fixes. #13024 fixes #9802 too, but drops the quirk on every T2 Mac, on the T2-less BCM4364 iMac19,x and on Apple Silicon. This pull request is older and is the narrower option. It does not miss any case that #9802 is about.

What it waits on. The maintainer. The only hardware result comes from the author of this pull request, who also opened #9802, so it cannot serve as independent confirmation. The MacBookPro15,2 report above was not tested against this head. Choosing between this scope and #13024's wider one is the maintainer's call.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working compatibility Make Omarchy work better on everything!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MacBookPro16,1 Broadcom quirk disables WPA3-SAE

4 participants