Skip to contentSkip to conversation

mt76: Enable NL80211_EXT_FEATURE_CQM_RSSI_LIST

PATCH In review Kristian Evensen 2 participants 4 messages Sep 1, 2018 – Sep 4, 2018

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 mt76: Enable NL80211_EXT_FEATURE_CQM_RSSI_LIST

Enable the use of CQM_RSSI_LIST with mt76-devices. The change has been tested with the mt7602, mt7603 and mt7621 PCI wifi-cards. I passed a list of RSSI thresholds to the driver, and when disconnecting/connecting the antenna(s) I got an event each time the RSSI went above/below a threshold.

While I have not been able to test the change with any of the mt76 USB-devices (no access to a device), the RX RSSI management code is shared between the two device types. Thus, CQM should also work with the mt76 USB-devices.

v1->v2:
* Updated commit message. Thanks Kalle Valo, Arend van Spriel, Lorenzo Bianconi and Andrew Zaborowski.

---
 drivers/net/wireless/mediatek/mt76/mac80211.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/net/wireless/mediatek/mt76/mac80211.c +2 -0
index 029d54bce9e8..3eb328ff8c0d 100644
@@ -305,6 +305,8 @@ int mt76_register_device(struct mt76_dev *dev, bool vht,
 
 	wiphy->features |= NL80211_FEATURE_ACTIVE_MONITOR;
 
+	wiphy_ext_feature_set(wiphy, NL80211_EXT_FEATURE_CQM_RSSI_LIST);
+
 	wiphy->available_antennas_tx = dev->antenna_mask;
 	wiphy->available_antennas_rx = dev->antenna_mask;
 
Signature · 1 line
2.14.1
#1 lore raw
Quoted 11 lines · Kristian Evensen

Enable the use of CQM_RSSI_LIST with mt76-devices. The change has been tested with the mt7602, mt7603 and mt7621 PCI wifi-cards. I passed a list of RSSI thresholds to the driver, and when disconnecting/connecting the antenna(s) I got an event each time the RSSI went above/below a threshold.

While I have not been able to test the change with any of the mt76 USB-devices (no access to a device), the RX RSSI management code is shared between the two device types. Thus, CQM should also work with the mt76 USB-devices.

Quoted 6 lines

v1->v2:
* Updated commit message. Thanks Kalle Valo, Arend van Spriel, Lorenzo Bianconi and Andrew Zaborowski.

---

The changelog should be here, after the '---' line, so that git can automatically drop it. But I can fix it before I commit, but in the future please add it to the correct place.

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches#changelog_missing

Signature · 1 line
Kalle Valo
#2 lore raw

Hi,

Quoted 4 lines · Kalle Valo

The changelog should be here, after the '---' line, so that git can automatically drop it. But I can fix it before I commit, but in the future please add it to the correct place.

Thanks for letting me know and thanks for fixing my error this time. I was not aware of this requirement, but will remember about it in the future.

BR,
Kristian

#3 lore raw
In reply to Kristian Evensen
Quoted 6 lines · Kristian Evensen

Enable the use of CQM_RSSI_LIST with mt76-devices. The change has been tested with the mt7602, mt7603 and mt7621 PCI wifi-cards. I passed a list of RSSI thresholds to the driver, and when disconnecting/connecting the antenna(s) I got an event each time the RSSI went above/below a threshold.

Quoted 6 lines

While I have not been able to test the change with any of the mt76 USB-devices (no access to a device), the RX RSSI management code is shared between the two device types. Thus, CQM should also work with the mt76 USB-devices.

Patch applied to wireless-drivers-next.git, thanks.

b37b30afc2b3 mt76: Enable NL80211_EXT_FEATURE_CQM_RSSI_LIST

Signature · 3 lines
https://patchwork.kernel.org/patch/10584647/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches