ath10k: fix patching mistake for AP/IBSS CSA
Mistakenly v1 of `ath10k: fix AP/IBSS CSA with
template based fw`
(81a9a17db5
) was
applied.
This patch applies the missing bits from v2:
* remove unnecessary locking
* add some (sanity) checks
There are no practical functionality differences
between v1 and v2.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
This commit is contained in:
parent
9ff4be96eb
commit
8513d95b4b
@ -1230,9 +1230,10 @@ static void ath10k_control_beaconing(struct ath10k_vif *arvif,
|
|||||||
if (!info->enable_beacon) {
|
if (!info->enable_beacon) {
|
||||||
ath10k_vdev_stop(arvif);
|
ath10k_vdev_stop(arvif);
|
||||||
|
|
||||||
spin_lock_bh(&arvif->ar->data_lock);
|
|
||||||
arvif->is_started = false;
|
arvif->is_started = false;
|
||||||
arvif->is_up = false;
|
arvif->is_up = false;
|
||||||
|
|
||||||
|
spin_lock_bh(&arvif->ar->data_lock);
|
||||||
ath10k_mac_vif_beacon_free(arvif);
|
ath10k_mac_vif_beacon_free(arvif);
|
||||||
spin_unlock_bh(&arvif->ar->data_lock);
|
spin_unlock_bh(&arvif->ar->data_lock);
|
||||||
|
|
||||||
@ -1466,6 +1467,11 @@ static void ath10k_mac_vif_ap_csa_count_down(struct ath10k_vif *arvif)
|
|||||||
struct ieee80211_vif *vif = arvif->vif;
|
struct ieee80211_vif *vif = arvif->vif;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
|
lockdep_assert_held(&arvif->ar->conf_mutex);
|
||||||
|
|
||||||
|
if (WARN_ON(!test_bit(WMI_SERVICE_BEACON_OFFLOAD, ar->wmi.svc_map)))
|
||||||
|
return;
|
||||||
|
|
||||||
if (arvif->vdev_type != WMI_VDEV_TYPE_AP)
|
if (arvif->vdev_type != WMI_VDEV_TYPE_AP)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -2091,9 +2097,7 @@ static void ath10k_bss_assoc(struct ieee80211_hw *hw,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
spin_lock_bh(&arvif->ar->data_lock);
|
|
||||||
arvif->is_up = true;
|
arvif->is_up = true;
|
||||||
spin_unlock_bh(&arvif->ar->data_lock);
|
|
||||||
|
|
||||||
/* Workaround: Some firmware revisions (tested with qca6174
|
/* Workaround: Some firmware revisions (tested with qca6174
|
||||||
* WLAN.RM.2.0-00073) have buggy powersave state machine and must be
|
* WLAN.RM.2.0-00073) have buggy powersave state machine and must be
|
||||||
@ -2135,9 +2139,7 @@ static void ath10k_bss_disassoc(struct ieee80211_hw *hw,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
spin_lock_bh(&arvif->ar->data_lock);
|
|
||||||
arvif->is_up = false;
|
arvif->is_up = false;
|
||||||
spin_unlock_bh(&arvif->ar->data_lock);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int ath10k_station_assoc(struct ath10k *ar,
|
static int ath10k_station_assoc(struct ath10k *ar,
|
||||||
|
@ -206,11 +206,9 @@ static int ath10k_wmi_tlv_event_bcn_tx_status(struct ath10k *ar,
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
spin_lock_bh(&ar->data_lock);
|
|
||||||
arvif = ath10k_get_arvif(ar, vdev_id);
|
arvif = ath10k_get_arvif(ar, vdev_id);
|
||||||
if (arvif && arvif->is_up)
|
if (arvif && arvif->is_up && arvif->vif->csa_active)
|
||||||
ieee80211_queue_work(ar->hw, &arvif->ap_csa_work);
|
ieee80211_queue_work(ar->hw, &arvif->ap_csa_work);
|
||||||
spin_unlock_bh(&ar->data_lock);
|
|
||||||
|
|
||||||
kfree(tb);
|
kfree(tb);
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user