summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/realtek/rtlwifi/rtl8188ee
diff options
context:
space:
mode:
authorPing-Ke Shih <pkshih@realtek.com>2019-11-18 11:14:55 +0800
committerKalle Valo <kvalo@codeaurora.org>2019-11-20 09:41:30 +0200
commit4c8c0d8f709d16f418a5d1962b4eda86ff570151 (patch)
tree538e6e6d69beb53aa467b82c532bfcc6063d1613 /drivers/net/wireless/realtek/rtlwifi/rtl8188ee
parent92541dd9dda5ab474751e24cdb4253eb290b8b33 (diff)
rtlwifi: set proper udelay within rf_serial_read
Since read RF register is an indirect access that hardware needs time to accomplish read action, but there's no ready bit, so delay is required to guarantee the read value is correct. After investigating internal documents, these delays are reduced as proper values. Reported-by: Lucas Stach <dev@lynxeye.de> Signed-off-by: Ping-Ke Shih <pkshih@realtek.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/realtek/rtlwifi/rtl8188ee')
-rw-r--r--drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c b/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c
index 01206651c7df..5ca900f97d66 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/phy.c
@@ -164,9 +164,9 @@ static u32 _rtl88e_phy_rf_serial_read(struct ieee80211_hw *hw,
(newoffset << 23) | BLSSIREADEDGE;
rtl_set_bbreg(hw, RFPGA0_XA_HSSIPARAMETER2, MASKDWORD,
tmplong & (~BLSSIREADEDGE));
- mdelay(1);
+ udelay(10);
rtl_set_bbreg(hw, pphyreg->rfhssi_para2, MASKDWORD, tmplong2);
- mdelay(2);
+ udelay(120);
if (rfpath == RF90_PATH_A)
rfpi_enable = (u8)rtl_get_bbreg(hw, RFPGA0_XA_HSSIPARAMETER1,
BIT(8));