linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mt76x2: set default values in TX_ALC_CFG_{1,2} for tempetaure compensation
       [not found] <cover.1522830473.git.lorenzo.bianconi@redhat.com>
@ 2018-04-04  8:38 ` Lorenzo Bianconi
  2018-04-24 17:32   ` mt76x2: set default values in TX_ALC_CFG_{1, 2} " Kalle Valo
  0 siblings, 1 reply; 2+ messages in thread
From: Lorenzo Bianconi @ 2018-04-04  8:38 UTC (permalink / raw)
  To: nbd; +Cc: linux-wireless

Initialize default values for temperature compensation in TX_ALC_CFG_{1,2}
if tssi has been enabled

Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
---
 drivers/net/wireless/mediatek/mt76/mt76x2_phy.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/wireless/mediatek/mt76/mt76x2_phy.c b/drivers/net/wireless/mediatek/mt76/mt76x2_phy.c
index 42414c5fa01e..daecc7ea900a 100644
--- a/drivers/net/wireless/mediatek/mt76/mt76x2_phy.c
+++ b/drivers/net/wireless/mediatek/mt76/mt76x2_phy.c
@@ -660,6 +660,14 @@ int mt76x2_phy_set_channel(struct mt76x2_dev *dev,
 	memcpy(dev->cal.agc_gain_cur, dev->cal.agc_gain_init,
 	       sizeof(dev->cal.agc_gain_cur));
 
+	/* init default values for temp compensation */
+	if (mt76x2_tssi_enabled(dev)) {
+		mt76_rmw_field(dev, MT_TX_ALC_CFG_1, MT_TX_ALC_CFG_1_TEMP_COMP,
+			       0x38);
+		mt76_rmw_field(dev, MT_TX_ALC_CFG_2, MT_TX_ALC_CFG_2_TEMP_COMP,
+			       0x38);
+	}
+
 	ieee80211_queue_delayed_work(mt76_hw(dev), &dev->cal_work,
 				     MT_CALIBRATE_INTERVAL);
 
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: mt76x2: set default values in TX_ALC_CFG_{1, 2} for tempetaure compensation
  2018-04-04  8:38 ` [PATCH] mt76x2: set default values in TX_ALC_CFG_{1,2} for tempetaure compensation Lorenzo Bianconi
@ 2018-04-24 17:32   ` Kalle Valo
  0 siblings, 0 replies; 2+ messages in thread
From: Kalle Valo @ 2018-04-24 17:32 UTC (permalink / raw)
  To: Lorenzo Bianconi; +Cc: nbd, linux-wireless

Lorenzo Bianconi <lorenzo.bianconi@redhat.com> wrote:

> Initialize default values for temperature compensation in TX_ALC_CFG_{1,2}
> if tssi has been enabled
> 
> Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>

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

b9e5d4feb4fc mt76x2: set default values in TX_ALC_CFG_{1, 2} for tempetaure compensation

-- 
https://patchwork.kernel.org/patch/10322225/

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

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-04-24 17:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <cover.1522830473.git.lorenzo.bianconi@redhat.com>
2018-04-04  8:38 ` [PATCH] mt76x2: set default values in TX_ALC_CFG_{1,2} for tempetaure compensation Lorenzo Bianconi
2018-04-24 17:32   ` mt76x2: set default values in TX_ALC_CFG_{1, 2} " Kalle Valo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).