Remove wrapper routine rtw_msleep_os()

The effect of this macro is to call msleep(). Remove the wrapper.

Link: https://lore.kernel.org/r/20210805192644.15978-2-Larry.Finger@lwfinger.net
This commit is contained in:
Larry Finger
2021-08-05 14:26:40 -05:00
committed by Carlos Garcés
parent 1fcfef2e07
commit fdbea81f08
25 changed files with 105 additions and 132 deletions

View File

@@ -1609,7 +1609,7 @@ int hal_read_mac_hidden_rpt(_adapter *adapter)
id = rtw_read8(adapter, REG_C2HEVT_MSG_NORMAL);
if (id == C2H_MAC_HIDDEN_RPT || RTW_CANNOT_IO(adapter))
break;
rtw_msleep_os(10);
msleep(10);
} while (rtw_get_passing_time_ms(start) < timeout_ms || cnt < min_cnt);
if (id == C2H_MAC_HIDDEN_RPT) {
@@ -4906,7 +4906,7 @@ static u8 rtw_hal_check_wow_ctrl(_adapter *adapter, u8 chk_type)
RTW_PRINT("Loop index: %d :0x%02x\n",
trycnt, reason);
trycnt--;
rtw_msleep_os(20);
msleep(20);
}
if (!reason)
res = _TRUE;
@@ -4919,7 +4919,7 @@ static u8 rtw_hal_check_wow_ctrl(_adapter *adapter, u8 chk_type)
RTW_PRINT("%s REG_FE1IMR (reg120): 0x%x, REG_RXPKT_NUM(reg284): 0x%x\n", __func__, fe1_imr, rxpkt_num);
while (((fe1_imr & BIT_FS_RXDONE_INT_EN) || (rxpkt_num & BIT_RW_RELEASE_EN)) && trycnt > 1) {
rtw_msleep_os(20);
msleep(20);
fe1_imr = rtw_read32(adapter, REG_FE1IMR);
rxpkt_num = rtw_read32(adapter, REG_RXPKT_NUM);
RTW_PRINT("Loop index: %d :0x%x, 0x%x\n",
@@ -4943,7 +4943,7 @@ static u8 rtw_hal_check_wow_ctrl(_adapter *adapter, u8 chk_type)
RTW_PRINT("Loop index: %d :0x%02x\n",
trycnt, mstatus);
trycnt--;
rtw_msleep_os(20);
msleep(20);
}
if (mstatus & BIT1)
res = _TRUE;
@@ -4955,7 +4955,7 @@ static u8 rtw_hal_check_wow_ctrl(_adapter *adapter, u8 chk_type)
RTW_PRINT("Loop index: %d :0x%02x\n",
trycnt, mstatus);
trycnt--;
rtw_msleep_os(20);
msleep(20);
}
if (mstatus & BIT1)
@@ -4984,7 +4984,7 @@ static u8 rtw_hal_check_pno_enabled(_adapter *adapter)
count, res);
res = rtw_read8(adapter, REG_PNO_STATUS);
count++;
rtw_msleep_os(2);
msleep(2);
}
if (res & BIT(7))
ret = _TRUE;
@@ -5799,7 +5799,7 @@ static void rtw_hal_set_ap_rsvdpage_loc_cmd(PADAPTER padapter,
if (ret == _FAIL)
RTW_INFO("%s: H2C_BCN_RSVDPAGE cmd fail\n", __func__);
rtw_msleep_os(10);
msleep(10);
_rtw_memset(&rsvdparm, 0, sizeof(rsvdparm));
@@ -5812,7 +5812,7 @@ static void rtw_hal_set_ap_rsvdpage_loc_cmd(PADAPTER padapter,
if (ret == _FAIL)
RTW_INFO("%s: H2C_PROBERSP_RSVDPAGE cmd fail\n", __func__);
rtw_msleep_os(10);
msleep(10);
}
static void rtw_hal_set_fw_ap_wow_related_cmd(_adapter *padapter, u8 enable)
@@ -5854,7 +5854,7 @@ static void rtw_hal_ap_wow_enable(_adapter *padapter)
issue_beacon(padapter, 0);
rtw_msleep_os(2);
msleep(2);
#if defined(CONFIG_RTL8188E)
if (IS_HARDWARE_TYPE_8188E(padapter))
rtw_hal_disable_tx_report(padapter);
@@ -5911,7 +5911,7 @@ static void rtw_hal_ap_wow_disable(_adapter *padapter)
rtw_hal_set_fw_ap_wow_related_cmd(padapter, 0);
rtw_msleep_os(2);
msleep(2);
#ifdef DBG_CHECK_FW_PS_STATE
if (rtw_fw_ps_state(padapter) == _FAIL) {
pdbgpriv->dbg_diswow_dload_fw_fail_cnt++;
@@ -11032,7 +11032,7 @@ int rtw_hal_reset_tsf(_adapter *adapter, u8 reset_port)
return ret;
while ((reset_cnt_after == reset_cnt_before) && (loop_cnt < 10)) {
rtw_msleep_os(100);
msleep(100);
loop_cnt++;
reset_cnt_after = rtw_read8(adapter, reg_reset_tsf_cnt);
}
@@ -11512,7 +11512,7 @@ void rtw_lps_state_chk(_adapter *adapter, u8 ps_mode)
ps_ready = _TRUE;
break;
}
rtw_msleep_os(1);
msleep(1);
} while (leave_wait_count--);
if (ps_ready == _FALSE) {
@@ -13612,7 +13612,7 @@ void rtw_reset_phy_rx_counters(_adapter *padapter)
phy_set_bb_reg(padapter, 0xA2C, BIT15, 0x1);
} else {
phy_set_bb_reg(padapter, 0xF14, BIT16, 0x1);
rtw_msleep_os(10);
msleep(10);
phy_set_bb_reg(padapter, 0xF14, BIT16, 0x0);
phy_set_bb_reg(padapter, 0xD00, BIT27, 0x1);/* reset OFDA FA counter */