Commit 80394da4 authored by Martin Kaiser's avatar Martin Kaiser Committed by Greg Kroah-Hartman

staging: r8188eu: remove rtw_usleep_os

Remove the rtw_usleep_os helper function. There are only two callers, both
of which call rtw_usleep_os(100). This is equivalent to msleep(1).

Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150
Tested-by: default avatarPavel Skripkin <paskripkin@gmail.com>
Signed-off-by: default avatarMartin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220626180603.287054-1-martin@kaiser.cxSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b78137d0
...@@ -273,7 +273,7 @@ static s32 LPS_RF_ON_check(struct adapter *padapter, u32 delay_ms) ...@@ -273,7 +273,7 @@ static s32 LPS_RF_ON_check(struct adapter *padapter, u32 delay_ms)
err = -1; err = -1;
break; break;
} }
rtw_usleep_os(100); msleep(1);
} }
return err; return err;
......
...@@ -243,7 +243,7 @@ static int efuse_read_phymap_from_txpktbuf( ...@@ -243,7 +243,7 @@ static int efuse_read_phymap_from_txpktbuf(
if (reg) if (reg)
break; break;
rtw_usleep_os(100); msleep(1);
} while (time_before(jiffies, timeout)); } while (time_before(jiffies, timeout));
/* data from EEPROM needs to be in LE */ /* data from EEPROM needs to be in LE */
......
...@@ -76,8 +76,6 @@ void *rtw_malloc2d(int h, int w, int size); ...@@ -76,8 +76,6 @@ void *rtw_malloc2d(int h, int w, int size);
spin_lock_init(&((q)->lock)); \ spin_lock_init(&((q)->lock)); \
} while (0) } while (0)
void rtw_usleep_os(int us);
static inline unsigned char _cancel_timer_ex(struct timer_list *ptimer) static inline unsigned char _cancel_timer_ex(struct timer_list *ptimer)
{ {
return del_timer_sync(ptimer); return del_timer_sync(ptimer);
......
...@@ -42,14 +42,6 @@ Otherwise, there will be racing condition. ...@@ -42,14 +42,6 @@ Otherwise, there will be racing condition.
Caller must check if the list is empty before calling rtw_list_delete Caller must check if the list is empty before calling rtw_list_delete
*/ */
void rtw_usleep_os(int us)
{
if (1 < (us / 1000))
msleep(1);
else
msleep((us / 1000) + 1);
}
static const struct device_type wlan_type = { static const struct device_type wlan_type = {
.name = "wlan", .name = "wlan",
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment