Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8afe0ece authored by Arend van Spriel's avatar Arend van Spriel Committed by Kalle Valo
Browse files

brcmfmac: update wiphy band information upon updating regulatory domain



When change the country code the available channels may change. So
the wiphy bands should be updated accordingly.

Reviewed-by: default avatarDaniel (Deognyoun) Kim <dekim@broadcom.com>
Reviewed-by: default avatarHante Meuleman <meuleman@broadcom.com>
Reviewed-by: default avatarPieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent 58de92d2
Loading
Loading
Loading
Loading
+5 −1
Original line number Original line Diff line number Diff line
@@ -6023,7 +6023,11 @@ static void brcmf_cfg80211_reg_notifier(struct wiphy *wiphy,
	memset(&ccreq, 0, sizeof(ccreq));
	memset(&ccreq, 0, sizeof(ccreq));
	ccreq.rev = cpu_to_le32(-1);
	ccreq.rev = cpu_to_le32(-1);
	memcpy(ccreq.ccode, req->alpha2, sizeof(req->alpha2));
	memcpy(ccreq.ccode, req->alpha2, sizeof(req->alpha2));
	brcmf_fil_iovar_data_set(ifp, "country", &ccreq, sizeof(ccreq));
	if (brcmf_fil_iovar_data_set(ifp, "country", &ccreq, sizeof(ccreq))) {
		brcmf_err("firmware rejected country setting\n");
		return;
	}
	brcmf_setup_wiphybands(wiphy);
}
}


static void brcmf_free_wiphy(struct wiphy *wiphy)
static void brcmf_free_wiphy(struct wiphy *wiphy)