staging: wilc1000: remove WILC_Sleep()
It was just a wrapper around usleep_range() so call that directly instead and remove the now-empty file. Cc: Johnny Kim <johnny.kim@atmel.com> Cc: Rachel Kim <rachel.kim@atmel.com> Cc: Dean Lee <dean.lee@atmel.com> Cc: Chris Park <chris.park@atmel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Родитель
bb7b1a76aa
Коммит
80e29c7a80
|
@ -26,7 +26,7 @@ ccflags-$(CONFIG_WILC1000_DYNAMICALLY_ALLOCATE_MEMROY) += -DWILC_NORMAL_ALLOC
|
|||
|
||||
|
||||
wilc1000-objs := wilc_wfi_cfgoperations.o linux_wlan.o linux_mon.o \
|
||||
wilc_memory.o wilc_msgqueue.o wilc_sleep.o \
|
||||
wilc_memory.o wilc_msgqueue.o \
|
||||
wilc_timer.o coreconfigurator.o host_interface.o \
|
||||
wilc_sdio.o wilc_spi.o wilc_wlan_cfg.o wilc_debugfs.o
|
||||
|
||||
|
|
|
@ -4339,7 +4339,7 @@ static int hostIFthread(void *pvArg)
|
|||
/*Re-Queue HIF message*/
|
||||
if ((!g_wilc_initialized)) {
|
||||
PRINT_D(GENERIC_DBG, "--WAIT--");
|
||||
WILC_Sleep(200);
|
||||
usleep_range(200 * 1000, 200 * 1000);
|
||||
WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
|
||||
continue;
|
||||
}
|
||||
|
@ -4347,7 +4347,7 @@ static int hostIFthread(void *pvArg)
|
|||
if (strHostIFmsg.u16MsgId == HOST_IF_MSG_CONNECT && pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult != NULL) {
|
||||
PRINT_D(HOSTINF_DBG, "Requeue connect request till scan done received\n");
|
||||
WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
|
||||
WILC_Sleep(2);
|
||||
usleep_range(2 * 1000, 2 * 1000);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
@ -23,9 +23,6 @@
|
|||
/* Error reporting and handling support */
|
||||
#include "wilc_errorsupport.h"
|
||||
|
||||
/* Sleep support */
|
||||
#include "wilc_sleep.h"
|
||||
|
||||
/* Timer support */
|
||||
#include "wilc_timer.h"
|
||||
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
|
||||
#include "wilc_sleep.h"
|
||||
|
||||
/*
|
||||
* @author mdaftedar
|
||||
* @date 10 Aug 2010
|
||||
* @version 1.0
|
||||
*/
|
||||
void WILC_Sleep(u32 u32TimeMilliSec)
|
||||
{
|
||||
if (u32TimeMilliSec <= 4000000) {
|
||||
u32 u32Temp = u32TimeMilliSec * 1000;
|
||||
usleep_range(u32Temp, u32Temp);
|
||||
} else {
|
||||
msleep(u32TimeMilliSec);
|
||||
}
|
||||
|
||||
}
|
|
@ -1,20 +0,0 @@
|
|||
#ifndef __WILC_SLEEP_H__
|
||||
#define __WILC_SLEEP_H__
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/delay.h>
|
||||
|
||||
/*!
|
||||
* @brief forces the current thread to sleep until the given time has elapsed
|
||||
* @param[in] u32TimeMilliSec Time to sleep in Milli seconds
|
||||
* @sa WILC_SleepMicrosec
|
||||
* @author syounan
|
||||
* @date 10 Aug 2010
|
||||
* @version 1.0
|
||||
* @note This function offers a relatively innacurate and low resolution
|
||||
* sleep, for accurate high resolution sleep use u32TimeMicoSec
|
||||
*/
|
||||
/* TODO: remove and open-code in callers */
|
||||
void WILC_Sleep(u32 u32TimeMilliSec);
|
||||
|
||||
#endif
|
|
@ -730,7 +730,7 @@ INLINE void chip_wakeup(void)
|
|||
|
||||
do {
|
||||
/* Wait for the chip to stabilize*/
|
||||
WILC_Sleep(2);
|
||||
usleep_range(2 * 1000, 2 * 1000);
|
||||
/* Make sure chip is awake. This is an extra step that can be removed */
|
||||
/* later to avoid the bus access overhead */
|
||||
if ((wilc_get_chipid(true) == 0)) {
|
||||
|
@ -753,7 +753,7 @@ INLINE void chip_wakeup(void)
|
|||
/* If still off, redo the wake up sequence */
|
||||
while (((clk_status_reg & 0x1) == 0) && (((++trials) % 3) == 0)) {
|
||||
/* Wait for the chip to stabilize*/
|
||||
WILC_Sleep(2);
|
||||
usleep_range(2 * 1000, 2 * 1000);
|
||||
|
||||
/* Make sure chip is awake. This is an extra step that can be removed */
|
||||
/* later to avoid the bus access overhead */
|
||||
|
@ -1408,7 +1408,7 @@ static void wilc_wlan_handle_isr_ext(uint32_t int_status)
|
|||
buffer = p->os_func.os_malloc(size);
|
||||
if (buffer == NULL) {
|
||||
wilc_debug(N_ERR, "[wilc isr]: fail alloc host memory...drop the packets (%d)\n", size);
|
||||
WILC_Sleep(100);
|
||||
usleep_range(100 * 1000, 100 * 1000);
|
||||
goto _end_;
|
||||
}
|
||||
#endif
|
||||
|
|
Загрузка…
Ссылка в новой задаче