Commit 8552a434 authored by John Crispin's avatar John Crispin Committed by Johannes Berg
Browse files

mac80211: rename csa counters to countdown counters



We want to reuse the functions and structs for other counters such as BSS
color change. Rename them to more generic names.

Signed-off-by: default avatarJohn Crispin <john@phrozen.org>
Link: https://lore.kernel.org/r/20200811080107.3615705-2-john@phrozen.org


Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 00c207ed
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -2019,8 +2019,8 @@ static void ath10k_mac_vif_ap_csa_count_down(struct ath10k_vif *arvif)
	if (!arvif->is_up)
		return;

	if (!ieee80211_csa_is_complete(vif)) {
		ieee80211_csa_update_counter(vif);
	if (!ieee80211_beacon_cntdwn_is_complete(vif)) {
		ieee80211_beacon_update_cntdwn(vif);

		ret = ath10k_mac_setup_bcn_tmpl(arvif);
		if (ret)
+1 −1
Original line number Diff line number Diff line
@@ -3878,7 +3878,7 @@ void ath10k_wmi_event_host_swba(struct ath10k *ar, struct sk_buff *skb)
		 * actual channel switch is done
		 */
		if (arvif->vif->csa_active &&
		    ieee80211_csa_is_complete(arvif->vif)) {
		    ieee80211_beacon_cntdwn_is_complete(arvif->vif)) {
			ieee80211_csa_finish(arvif->vif);
			continue;
		}
+2 −2
Original line number Diff line number Diff line
@@ -1593,8 +1593,8 @@ int ath11k_wmi_bcn_tmpl(struct ath11k *ar, u32 vdev_id,
			  FIELD_PREP(WMI_TLV_LEN, sizeof(*cmd) - TLV_HDR_SIZE);
	cmd->vdev_id = vdev_id;
	cmd->tim_ie_offset = offs->tim_offset;
	cmd->csa_switch_count_offset = offs->csa_counter_offs[0];
	cmd->ext_csa_switch_count_offset = offs->csa_counter_offs[1];
	cmd->csa_switch_count_offset = offs->cntdwn_counter_offs[0];
	cmd->ext_csa_switch_count_offset = offs->cntdwn_counter_offs[1];
	cmd->buf_len = bcn->len;

	ptr = skb->data + sizeof(*cmd);
+1 −1
Original line number Diff line number Diff line
@@ -365,7 +365,7 @@ bool ath9k_csa_is_finished(struct ath_softc *sc, struct ieee80211_vif *vif)
	if (!vif || !vif->csa_active)
		return false;

	if (!ieee80211_csa_is_complete(vif))
	if (!ieee80211_beacon_cntdwn_is_complete(vif))
		return false;

	ieee80211_csa_finish(vif);
+1 −1
Original line number Diff line number Diff line
@@ -514,7 +514,7 @@ bool ath9k_htc_csa_is_finished(struct ath9k_htc_priv *priv)
	if (!vif || !vif->csa_active)
		return false;

	if (!ieee80211_csa_is_complete(vif))
	if (!ieee80211_beacon_cntdwn_is_complete(vif))
		return false;

	ieee80211_csa_finish(vif);
Loading