|
@@ -155,6 +155,9 @@ mt76x2_config(struct ieee80211_hw *hw, u32 changed)
|
|
|
if (changed & IEEE80211_CONF_CHANGE_POWER) {
|
|
|
dev->txpower_conf = hw->conf.power_level * 2;
|
|
|
|
|
|
+ /* convert to per-chain power for 2x2 devices */
|
|
|
+ dev->txpower_conf -= 6;
|
|
|
+
|
|
|
if (test_bit(MT76_STATE_RUNNING, &dev->mt76.state)) {
|
|
|
mt76x2_phy_set_txpower(dev);
|
|
|
mt76x2_tx_set_txpwr_auto(dev, dev->txpower_conf);
|
|
@@ -437,6 +440,10 @@ mt76x2_get_txpower(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int *dbm)
|
|
|
struct mt76x2_dev *dev = hw->priv;
|
|
|
|
|
|
*dbm = dev->txpower_cur / 2;
|
|
|
+
|
|
|
+ /* convert from per-chain power to combined output on 2x2 devices */
|
|
|
+ *dbm += 3;
|
|
|
+
|
|
|
return 0;
|
|
|
}
|
|
|
|