diff options
author | Hans Ulli Kroll <ulli.kroll@googlemail.com> | 2015-06-07 13:19:16 +0200 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2015-06-15 12:30:20 +0300 |
commit | 1637c1b7ebbb51de63b71c7eebcfff6407a0be72 (patch) | |
tree | 60b608d9e212dab76d85968a468c383d9f0c01ec /drivers/net/wireless/rtlwifi/rtl8192se | |
parent | fbcaee1c6da13d10b8fb7810d76fb8ce92dd9226 (diff) | |
download | op-kernel-dev-1637c1b7ebbb51de63b71c7eebcfff6407a0be72.zip op-kernel-dev-1637c1b7ebbb51de63b71c7eebcfff6407a0be72.tar.gz |
rtlwifi: fix tm_trigger usage
While working on getting my rtl8821au driver in pretty shape for
inclusion, it is dicosvered that the tm_trigger flag is used only for
the first device using this driver.
This flag handles the thermal power management in the hardware.
To change this add a entry in sttruct rtl_dm, so each device can handle
is separately.
Signed-off-by: Hans Ulli Kroll <ulli.kroll@googlemail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/rtlwifi/rtl8192se')
-rw-r--r-- | drivers/net/wireless/rtlwifi/rtl8192se/dm.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192se/dm.c b/drivers/net/wireless/rtlwifi/rtl8192se/dm.c index 575980b..9bae5a9 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192se/dm.c +++ b/drivers/net/wireless/rtlwifi/rtl8192se/dm.c @@ -200,7 +200,6 @@ static void _rtl92s_dm_check_txpowertracking_thermalmeter( { struct rtl_priv *rtlpriv = rtl_priv(hw); struct rtl_phy *rtlphy = &(rtlpriv->phy); - static u8 tm_trigger; u8 tx_power_checkcnt = 5; /* 2T2R TP issue */ @@ -215,13 +214,13 @@ static void _rtl92s_dm_check_txpowertracking_thermalmeter( return; } - if (!tm_trigger) { + if (!rtlpriv->dm.tm_trigger) { rtl_set_rfreg(hw, RF90_PATH_A, RF_T_METER, RFREG_OFFSET_MASK, 0x60); - tm_trigger = 1; + rtlpriv->dm.tm_trigger = 1; } else { _rtl92s_dm_txpowertracking_callback_thermalmeter(hw); - tm_trigger = 0; + rtlpriv->dm.tm_trigger = 0; } } |