Linux wireless drivers development
 help / color / mirror / Atom feed
* [PATCH] wifi: brcmfmac: allow ISO3166 fallback for BCM4350
@ 2026-09-01 18:49 Vinícius Ramon Fontanela
  2026-09-14 20:03 ` Arend van Spriel
  0 siblings, 1 reply; 4+ messages in thread
From: Vinícius Ramon Fontanela @ 2026-09-01 18:49 UTC (permalink / raw)
  To: linux-wireless; +Cc: arend.vanspriel, brcm80211, brcm80211-dev-list.pdl

From: Vinícius Ramon Fontanela <vfontanela@gmail.com>

BCM4350 devices using brcmfmac on x86/PCIe may have no platform-provided
country code map. In that case brcmf_translate_country_code() falls back
to ISO3166 codes only for chips accepted by
brmcf_use_iso3166_ccode_fallback(). BCM4350 is currently missing from
that list, despite the adjacent BCM4345 and BCM4356 being present.

Without a country_codes table, BCM4350 therefore returns -EINVAL from
brcmf_translate_country_code(). brcmf_cfg80211_reg_notifier() silently
returns at that point, so the firmware never receives the requested
country iovar. On a MacBookPro14,1 with BCM4350 PCI device 14e4:43a3,
this left the firmware unable to scan UNII-2e DFS channels 100-144 even
though cfg80211 exposed those channels as available.

Adding BCM4350 to the ISO3166 fallback fixes the issue. Tested on a 2017
13-inch MacBook Pro (MacBookPro14,1), Fedora 44, kernel 7.1.12, with an
AP on channel 116 (5580 MHz). Before the change the AP was absent from
scans; after the change it is detected and NetworkManager connects to it
normally.

Signed-off-by: Vinícius Ramon Fontanela <vfontanela@gmail.com>
---
 drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
index 000000000000..000000000000 100644
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
@@ -7948,6 +7948,7 @@ static bool
brmcf_use_iso3166_ccode_fallback(struct brcmf_pub *drvr)
 	switch (drvr->bus_if->chip) {
 	case BRCM_CC_43430_CHIP_ID:
 	case BRCM_CC_4345_CHIP_ID:
+	case BRCM_CC_4350_CHIP_ID:
 	case BRCM_CC_4356_CHIP_ID:
 	case BRCM_CC_43602_CHIP_ID:
 		return true;
-- 
2.51.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-10-04  9:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-01 18:49 [PATCH] wifi: brcmfmac: allow ISO3166 fallback for BCM4350 Vinícius Ramon Fontanela
2026-09-14 20:03 ` Arend van Spriel
2026-09-15 17:43   ` [PATCH v2] " Vinícius Ramon Fontanela
2026-10-04  9:45     ` Arend van Spriel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox