[PATCH 3/3] mt76: mt7921: introduce BIOS SAR config in tx power
Deren Wu
deren.wu at mediatek.com
Thu May 19 09:22:05 PDT 2022
Hi Felix,
On Thu, 2022-05-19 at 17:33 +0200, Felix Fietkau wrote:
> On 19.05.22 08:38, Deren Wu wrote:
> > From: Deren Wu <deren.wu at mediatek.com>
> >
> > Add new function mt7921_set_tx_sar_pwr() to update SAR power from
> > .set_sar_specs and BIOS setting. Both settings would be merged into
> > mt76_freq_range_power for final tx power value.
> >
> > Reviewed-by: Sean Wang <sean.wang at mediatek.com>
> > Co-developed-by: Ming Yen Hsieh <mingyen.hsieh at mediatek.com>
> > Signed-off-by: Ming Yen Hsieh <mingyen.hsieh at mediatek.com>
> > Signed-off-by: Deren Wu <deren.wu at mediatek.com>
> > ---
> > .../net/wireless/mediatek/mt76/mt7921/init.c | 3 +-
> > .../net/wireless/mediatek/mt76/mt7921/main.c | 32 +++++++++++++-
> > -----
> > .../wireless/mediatek/mt76/mt7921/mt7921.h | 2 ++
> > 3 files changed, 26 insertions(+), 11 deletions(-)
> >
> > diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/main.c
> > b/drivers/net/wireless/mediatek/mt76/mt7921/main.c
> > index 80279f342109..c86d8805f291 100644
> > --- a/drivers/net/wireless/mediatek/mt76/mt7921/main.c
> > +++ b/drivers/net/wireless/mediatek/mt76/mt7921/main.c
> > @@ -1469,20 +1469,34 @@ static void mt7921_ipv6_addr_change(struct
> > ieee80211_hw *hw,
> > }
> > #endif
> >
> > +int mt7921_set_tx_sar_pwr(struct ieee80211_hw *hw,
> > + const struct cfg80211_sar_specs *sar)
> > +{
> > + struct mt76_phy *mphy = hw->priv;
> > + int err;
> > +
> > + if (sar) {
> > + err = mt76_init_sar_power(hw, sar);
> > + if (err)
> > + return err;
> > + }
> > +
> > + mt7921_init_bios_sar_power(mt7921_hw_phy(hw), !sar);
> > +
> > + err = mt76_connac_mcu_set_rate_txpower(mphy);
> > +
> > + return err;
> > +}
> > +EXPORT_SYMBOL_GPL(mt7921_set_tx_sar_pwr);
>
> Why is this exported?
Thanks for pointing out. I will remove unnecessary export in next
version.
Regards,
Deren
>
> - Felix
>
> _______________________________________________
> Linux-mediatek mailing list
> Linux-mediatek at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-mediatek
More information about the Linux-mediatek
mailing list