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

Commit b0178b91 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "cfg80211: Use new wiphy flag WIPHY_FLAG_DFS_OFFLOAD"

parents a1ac08de 1775b69b
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -273,7 +273,8 @@ static int cfg80211_get_chans_dfs_required(struct wiphy *wiphy,
		if (!c)
			return -EINVAL;

		if (c->flags & IEEE80211_CHAN_RADAR)
		if ((c->flags & IEEE80211_CHAN_RADAR) &&
		    !(wiphy->flags & WIPHY_FLAG_DFS_OFFLOAD))
			return 1;
	}
	return 0;
@@ -320,7 +321,8 @@ static bool cfg80211_secondary_chans_ok(struct wiphy *wiphy,
			return false;

		/* check for radar flags */
		if ((prohibited_flags & c->flags & IEEE80211_CHAN_RADAR) &&
		if ((!(wiphy->flags & WIPHY_FLAG_DFS_OFFLOAD)) &&
		    (prohibited_flags & c->flags & IEEE80211_CHAN_RADAR) &&
		    (c->dfs_state != NL80211_DFS_AVAILABLE))
			return false;

+3 −0
Original line number Diff line number Diff line
@@ -5710,6 +5710,9 @@ static int nl80211_start_radar_detection(struct sk_buff *skb,
	if (err)
		return err;

	if (rdev->wiphy.flags & WIPHY_FLAG_DFS_OFFLOAD)
		return -EOPNOTSUPP;

	if (wdev->cac_started)
		return -EBUSY;

+3 −1
Original line number Diff line number Diff line
@@ -1256,7 +1256,9 @@ int cfg80211_can_use_iftype_chan(struct cfg80211_registered_device *rdev,
	case NL80211_IFTYPE_P2P_GO:
	case NL80211_IFTYPE_WDS:
		radar_required = !!(chan &&
				    (chan->flags & IEEE80211_CHAN_RADAR));
				    (chan->flags & IEEE80211_CHAN_RADAR) &&
				    !(rdev->wiphy.flags &
				      WIPHY_FLAG_DFS_OFFLOAD));
		break;
	case NL80211_IFTYPE_P2P_CLIENT:
	case NL80211_IFTYPE_STATION: