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

Commit 6efa255a authored by Ryan Hsu's avatar Ryan Hsu Committed by Gerrit - the friendly Code Review server
Browse files

cfg80211: Bypass checkin the CHAN_RADAR if DFS_OFFLOAD is enabled



When WIPHY_FLAG_DFS_OFFLOAD is defined, driver would take care the
DFS related operation, hence the Kernel needs to ignore the DFS
states checking.

CRs-fixed: 867264
Change-Id: I02fa5e3e25427c0ca474455fa2d2be9eb6ea4bd9
Signed-off-by: default avatarRyan Hsu <ryanhsu@codeaurora.org>
parent c67f84f6
Loading
Loading
Loading
Loading
+9 −2
Original line number Diff line number Diff line
@@ -592,10 +592,17 @@ static bool cfg80211_secondary_chans_ok(struct wiphy *wiphy,

	for (freq = start_freq; freq <= end_freq; freq += 20) {
		c = ieee80211_get_channel(wiphy, freq);
		if (!c || c->flags & prohibited_flags)

		if (!c)
			return false;

		if ((!(wiphy->flags & WIPHY_FLAG_DFS_OFFLOAD)) &&
		    (c->flags & prohibited_flags & IEEE80211_CHAN_RADAR))
			return false;
	}

		if (c->flags & prohibited_flags & ~IEEE80211_CHAN_RADAR)
			return false;
	}
	return true;
}