mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
wifi: mt76: mt7921: cqm rssi low/high event notify
The implementation amounts to setting the driver flag IEEE80211_VIF_SUPPORTS_CQM_RSSI, and then providing mechanisms for continuously updating enough information to be able to provide notifications to userspace when RSSI drops below a certain threshold Signed-off-by: Rong Yan <[email protected]> Signed-off-by: Ming Yen Hsieh <[email protected]> Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
@@ -313,6 +313,8 @@ mt7921_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
|
||||
}
|
||||
|
||||
vif->driver_flags |= IEEE80211_VIF_BEACON_FILTER;
|
||||
if (phy->chip_cap & MT792x_CHIP_CAP_RSSI_NOTIFY_EVT_EN)
|
||||
vif->driver_flags |= IEEE80211_VIF_SUPPORTS_CQM_RSSI;
|
||||
out:
|
||||
mt792x_mutex_release(dev);
|
||||
|
||||
@@ -682,6 +684,9 @@ static void mt7921_bss_info_changed(struct ieee80211_hw *hw,
|
||||
if (changed & BSS_CHANGED_PS)
|
||||
mt7921_mcu_uni_bss_ps(dev, vif);
|
||||
|
||||
if (changed & BSS_CHANGED_CQM)
|
||||
mt7921_mcu_set_rssimonitor(dev, vif);
|
||||
|
||||
if (changed & BSS_CHANGED_ASSOC) {
|
||||
mt7921_mcu_sta_update(dev, NULL, vif, true,
|
||||
MT76_STA_INFO_STATE_ASSOC);
|
||||
|
||||
Reference in New Issue
Block a user