mirror of
https://github.com/torvalds/linux.git
synced 2026-06-08 14:42:37 +02:00
wifi: mt76: mt7921: fix wrong power after multiple SAR set
[ Upstream commit7eefb93d4a] We should update CLC config before SAR set to synchronize all related settings. Fixes:23bdc5d8ca("wifi: mt76: mt7921: introduce Country Location Control support") Signed-off-by: YN Chen <YN.Chen@mediatek.com> Signed-off-by: Deren Wu <deren.wu@mediatek.com> Signed-off-by: Felix Fietkau <nbd@nbd.name> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
71e73d3ce2
commit
f11c5a1926
|
|
@ -37,6 +37,7 @@ mt7921_regd_notifier(struct wiphy *wiphy,
|
|||
|
||||
memcpy(dev->mt76.alpha2, request->alpha2, sizeof(dev->mt76.alpha2));
|
||||
dev->mt76.region = request->dfs_region;
|
||||
dev->country_ie_env = request->country_ie_env;
|
||||
|
||||
mt7921_mutex_acquire(dev);
|
||||
mt7921_mcu_set_clc(dev, request->alpha2, request->country_ie_env);
|
||||
|
|
|
|||
|
|
@ -1504,7 +1504,13 @@ static int mt7921_set_sar_specs(struct ieee80211_hw *hw,
|
|||
int err;
|
||||
|
||||
mt7921_mutex_acquire(dev);
|
||||
err = mt7921_mcu_set_clc(dev, dev->mt76.alpha2,
|
||||
dev->country_ie_env);
|
||||
if (err < 0)
|
||||
goto out;
|
||||
|
||||
err = mt7921_set_tx_sar_pwr(hw, sar);
|
||||
out:
|
||||
mt7921_mutex_release(dev);
|
||||
|
||||
return err;
|
||||
|
|
|
|||
|
|
@ -244,6 +244,8 @@ struct mt7921_dev {
|
|||
struct work_struct ipv6_ns_work;
|
||||
/* IPv6 addresses for WoWLAN */
|
||||
struct sk_buff_head ipv6_ns_list;
|
||||
|
||||
enum environment_cap country_ie_env;
|
||||
};
|
||||
|
||||
enum {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user