WILC_CATCH(s32Error)
{
- WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hScanTimer);
/*if there is an ongoing scan request*/
Handle_ScanDone(drvHandler, SCAN_EVENT_ABORTED);
}
{
tstrConnectInfo strConnectInfo;
- WILC_TimerStop(&(pstrWFIDrv->hConnectTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hConnectTimer);
PRINT_D(HOSTINF_DBG, "could not start connecting to the required network\n");
}
- WILC_TimerStop(&(pstrWFIDrv->hConnectTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hConnectTimer);
pstrWFIDrv->strWILC_UsrConnReq.pfUserConnectResult(CONN_DISCONN_EVENT_CONN_RESP,
&strConnectInfo,
u8MacStatus,
#ifdef DISABLE_PWRSAVE_AND_SCAN_DURING_IP
PRINT_D(GENERIC_DBG, "Obtaining an IP, Disable Scan\n");
g_obtainingIP = true;
- WILC_TimerStart(&hDuringIpTimer, 10000, NULL, NULL);
+ WILC_TimerStart(&hDuringIpTimer, 10000, NULL);
#endif
#ifdef WILC_PARSE_SCAN_IN_HOST
if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult) {
PRINT_D(HOSTINF_DBG, "\n\n<< Abort the running OBSS Scan >>\n\n");
- WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hScanTimer);
Handle_ScanDone((void *)pstrWFIDrv, SCAN_EVENT_ABORTED);
}
PRINT_D(HOSTINF_DBG, "Received MAC_DISCONNECTED from the FW while scanning\n");
PRINT_D(HOSTINF_DBG, "\n\n<< Abort the running Scan >>\n\n");
/*Abort the running scan*/
- WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hScanTimer);
if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult)
Handle_ScanDone(pstrWFIDrv, SCAN_EVENT_ABORTED);
strDisconnectNotifInfo.ie_len = 0;
if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult) {
- WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hScanTimer);
pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult(SCAN_EVENT_ABORTED, NULL,
pstrWFIDrv->strWILC_UsrScanReq.u32UserScanPvoid, NULL);
/*Stop connect timer, if connection in progress*/
if (pstrWFIDrv->enuHostIFstate == HOST_IF_WAITING_CONN_RESP) {
PRINT_D(HOSTINF_DBG, "Upper layer requested termination of connection\n");
- WILC_TimerStop(&(pstrWFIDrv->hConnectTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hConnectTimer);
}
pstrWFIDrv->strWILC_UsrConnReq.pfUserConnectResult(CONN_DISCONN_EVENT_DISCONN_NOTIF, NULL,
WILC_CATCH(-1)
{
P2P_LISTEN_STATE = 1;
- WILC_TimerStart(&(pstrWFIDrv->hRemainOnChannel), pstrHostIfRemainOnChan->u32duration, (void *)pstrWFIDrv, NULL);
+ WILC_TimerStart(&(pstrWFIDrv->hRemainOnChannel), pstrHostIfRemainOnChan->u32duration, (void *)pstrWFIDrv);
/*Calling CFG ready_on_channel*/
if (pstrWFIDrv->strHostIfRemainOnChan.pRemainOnChanReady)
tstrHostIFmsg strHostIFmsg;
tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)pvArg;
/*Stopping remain-on-channel timer*/
- WILC_TimerStop(&(pstrWFIDrv->hRemainOnChannel), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hRemainOnChannel);
/* prepare the Timer Callback message */
memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
break;
case HOST_IF_MSG_RCVD_SCAN_COMPLETE:
- WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hScanTimer);
PRINT_D(HOSTINF_DBG, "scan completed successfully\n");
/*BugID_5213*/
}
enuScanConnTimer = CONNECT_TIMER;
- WILC_TimerStart(&(pstrWFIDrv->hConnectTimer), HOST_IF_CONNECT_TIMEOUT, (void *) hWFIDrv, NULL);
+ WILC_TimerStart(&(pstrWFIDrv->hConnectTimer), HOST_IF_CONNECT_TIMEOUT, (void *) hWFIDrv);
WILC_CATCH(s32Error)
{
enuScanConnTimer = SCAN_TIMER;
PRINT_D(HOSTINF_DBG, ">> Starting the SCAN timer\n");
- WILC_TimerStart(&(pstrWFIDrv->hScanTimer), HOST_IF_SCAN_TIMEOUT, (void *) hWFIDrv, NULL);
+ WILC_TimerStart(&(pstrWFIDrv->hScanTimer), HOST_IF_SCAN_TIMEOUT, (void *) hWFIDrv);
WILC_CATCH(s32Error)
return;
}
}
- WILC_TimerStart(&(g_hPeriodicRSSI), 5000, (void *)pstrWFIDrv, NULL);
+ WILC_TimerStart(&(g_hPeriodicRSSI), 5000, (void *)pstrWFIDrv);
}
s32Error = WILC_FAIL;
goto _fail_mq_;
}
- s32Error = WILC_TimerCreate(&(g_hPeriodicRSSI), GetPeriodicRSSI, NULL);
+ s32Error = WILC_TimerCreate(&(g_hPeriodicRSSI), GetPeriodicRSSI);
if (s32Error < 0) {
PRINT_ER("Failed to creat Timer\n");
goto _fail_timer_1;
}
- WILC_TimerStart(&(g_hPeriodicRSSI), 5000, (void *)pstrWFIDrv, NULL);
+ WILC_TimerStart(&(g_hPeriodicRSSI), 5000, (void *)pstrWFIDrv);
}
- s32Error = WILC_TimerCreate(&(pstrWFIDrv->hScanTimer), TimerCB_Scan, NULL);
+ s32Error = WILC_TimerCreate(&(pstrWFIDrv->hScanTimer), TimerCB_Scan);
if (s32Error < 0) {
PRINT_ER("Failed to creat Timer\n");
goto _fail_thread_;
}
- s32Error = WILC_TimerCreate(&(pstrWFIDrv->hConnectTimer), TimerCB_Connect, NULL);
+ s32Error = WILC_TimerCreate(&(pstrWFIDrv->hConnectTimer), TimerCB_Connect);
if (s32Error < 0) {
PRINT_ER("Failed to creat Timer\n");
goto _fail_timer_1;
#ifdef WILC_P2P
/*Remain on channel timer*/
- s32Error = WILC_TimerCreate(&(pstrWFIDrv->hRemainOnChannel), ListenTimerCB, NULL);
+ s32Error = WILC_TimerCreate(&(pstrWFIDrv->hRemainOnChannel), ListenTimerCB);
if (s32Error < 0) {
PRINT_ER("Failed to creat Remain-on-channel Timer\n");
goto _fail_timer_3;
kfree(pstrWFIDrv);
#ifdef WILC_P2P
_fail_timer_3:
- WILC_TimerDestroy(&(pstrWFIDrv->hRemainOnChannel), NULL);
+ WILC_TimerDestroy(&pstrWFIDrv->hRemainOnChannel);
#endif
_fail_timer_2:
up(&(pstrWFIDrv->gtOsCfgValuesSem));
- WILC_TimerDestroy(&(pstrWFIDrv->hConnectTimer), NULL);
+ WILC_TimerDestroy(&pstrWFIDrv->hConnectTimer);
_fail_timer_1:
- WILC_TimerDestroy(&(pstrWFIDrv->hScanTimer), NULL);
+ WILC_TimerDestroy(&pstrWFIDrv->hScanTimer);
_fail_thread_:
kthread_stop(HostIFthreadHandler);
_fail_mq_:
/*BugID_5348*/
/*Destroy all timers before acquiring hSemDeinitDrvHandle*/
/*to guarantee handling all messages befor proceeding*/
- if (WILC_TimerDestroy(&(pstrWFIDrv->hScanTimer), NULL)) {
+ if (WILC_TimerDestroy(&pstrWFIDrv->hScanTimer)) {
PRINT_D(HOSTINF_DBG, ">> Scan timer is active\n");
/* msleep(HOST_IF_SCAN_TIMEOUT+1000); */
}
- if (WILC_TimerDestroy(&(pstrWFIDrv->hConnectTimer), NULL)) {
+ if (WILC_TimerDestroy(&pstrWFIDrv->hConnectTimer)) {
PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
/* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
}
- if (WILC_TimerDestroy(&(g_hPeriodicRSSI), NULL)) {
+ if (WILC_TimerDestroy(&g_hPeriodicRSSI)) {
PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
/* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
}
#ifdef WILC_P2P
/*Destroy Remain-onchannel Timer*/
- WILC_TimerDestroy(&(pstrWFIDrv->hRemainOnChannel), NULL);
+ WILC_TimerDestroy(&pstrWFIDrv->hRemainOnChannel);
#endif
host_int_set_wfi_drv_handler(NULL);
memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
if (clients_count == 1) {
- if (WILC_TimerDestroy(&g_hPeriodicRSSI, NULL)) {
+ if (WILC_TimerDestroy(&g_hPeriodicRSSI)) {
PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
/* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
}
WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
/*Stopping remain-on-channel timer*/
- WILC_TimerStop(&(pstrWFIDrv->hRemainOnChannel), NULL);
+ WILC_TimerStop(&pstrWFIDrv->hRemainOnChannel);
/* prepare the timer fire Message */
memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
typedef void (*tpfWILC_TimerFunction)(void *);
-/*!
- * @struct tstrWILC_TimerAttrs
- * @brief Timer API options
- * @author syounan
- * @date 16 Aug 2010
- * @version 1.0
- */
-typedef struct {
- /* a dummy member to avoid compiler errors*/
- u8 dummy;
-} tstrWILC_TimerAttrs;
-
/*!
* @brief Creates a new timer
* @details Timers are a useful utility to execute some callback function
* and only flags other threads to do the actual work
* also it should be noted that the underlaying OS maynot give any
* guarentees on which contect this callback will execute in
- * @param[in] pstrAttrs Optional attributes, NULL for default
* @return Error code indicating sucess/failure
* @sa WILC_TimerAttrs
* @author syounan
* @version 1.0
*/
WILC_ErrNo WILC_TimerCreate(struct timer_list *pHandle,
- tpfWILC_TimerFunction pfCallback, tstrWILC_TimerAttrs *pstrAttrs);
+ tpfWILC_TimerFunction pfCallback);
/*!
* if the timer was EXECUTING then the callback will be allowed to
* finish first then all resources are freed
* @param[in] pHandle handle to the timer object
- * @param[in] pstrAttrs Optional attributes, NULL for default
* @return Error code indicating sucess/failure
* @sa WILC_TimerAttrs
* @author syounan
* @date 16 Aug 2010
* @version 1.0
*/
-WILC_ErrNo WILC_TimerDestroy(struct timer_list *pHandle,
- tstrWILC_TimerAttrs *pstrAttrs);
+WILC_ErrNo WILC_TimerDestroy(struct timer_list *pHandle);
/*!
* @brief Starts a given timer
* @param[in] u32Timeout timeout value in msec after witch the callback
* function will be executed. Timeout value of 0 is not allowed for
* periodic timers
- * @param[in] pstrAttrs Optional attributes, NULL for default,
- * set bPeriodicTimer to run this timer as a periodic timer
* @return Error code indicating sucess/failure
* @sa WILC_TimerAttrs
* @author syounan
* @date 16 Aug 2010
* @version 1.0
*/
-WILC_ErrNo WILC_TimerStart(struct timer_list *pHandle, u32 u32Timeout, void *pvArg,
- tstrWILC_TimerAttrs *pstrAttrs);
+WILC_ErrNo WILC_TimerStart(struct timer_list *pHandle, u32 u32Timeout, void *pvArg);
/*!
* done then move the timer to the IDLE state (which is trivial
* work if the timer is non periodic)
* @param[in] pHandle handle to the timer object
- * @param[in] pstrAttrs Optional attributes, NULL for default,
* @return Error code indicating sucess/failure
* @sa WILC_TimerAttrs
* @author syounan
* @date 16 Aug 2010
* @version 1.0
*/
-WILC_ErrNo WILC_TimerStop(struct timer_list *pHandle,
- tstrWILC_TimerAttrs *pstrAttrs);
+WILC_ErrNo WILC_TimerStop(struct timer_list *pHandle);
{
int i;
if (op_ifcs == 0) {
- WILC_TimerDestroy(&hAgingTimer, NULL);
+ WILC_TimerDestroy(&hAgingTimer);
PRINT_INFO(CORECONFIG_DBG, "destroy aging timer\n");
for (i = 0; i < u32LastScannedNtwrksCountShadow; i++) {
PRINT_D(CFG80211_DBG, "Number of cached networks: %d\n", u32LastScannedNtwrksCountShadow);
if (u32LastScannedNtwrksCountShadow != 0)
- WILC_TimerStart(&(hAgingTimer), AGING_TIME, pUserVoid, NULL);
+ WILC_TimerStart(&(hAgingTimer), AGING_TIME, pUserVoid);
else
PRINT_D(CFG80211_DBG, "No need to restart Aging timer\n");
}
if (u32LastScannedNtwrksCountShadow == 0) {
PRINT_D(CFG80211_DBG, "Starting Aging timer\n");
- WILC_TimerStart(&(hAgingTimer), AGING_TIME, pUserVoid, NULL);
+ WILC_TimerStart(&(hAgingTimer), AGING_TIME, pUserVoid);
state = -1;
} else {
/* Linear search for now */
#ifdef DISABLE_PWRSAVE_AND_SCAN_DURING_IP
g_obtainingIP = false;
- WILC_TimerStop(&hDuringIpTimer, NULL);
+ WILC_TimerStop(&hDuringIpTimer);
PRINT_D(GENERIC_DBG, "Changing virtual interface, enable scan\n");
#endif
/*BugID_5137*/
#ifdef DISABLE_PWRSAVE_AND_SCAN_DURING_IP
g_obtainingIP = true;
- WILC_TimerStart(&hDuringIpTimer, duringIP_TIME, NULL, NULL);
+ WILC_TimerStart(&hDuringIpTimer, duringIP_TIME, NULL);
#endif
host_int_set_power_mgmt(priv->hWILCWFIDrv, 0, 0);
/*BugID_5222*/
PRINT_D(INIT_DBG, "Host[%p][%p]\n", net, net->ieee80211_ptr);
priv = wdev_priv(net->ieee80211_ptr);
if (op_ifcs == 0) {
- s32Error = WILC_TimerCreate(&(hAgingTimer), remove_network_from_shadow, NULL);
+ s32Error = WILC_TimerCreate(&(hAgingTimer), remove_network_from_shadow);
#ifdef DISABLE_PWRSAVE_AND_SCAN_DURING_IP
- s32Error = WILC_TimerCreate(&(hDuringIpTimer), clear_duringIP, NULL);
+ s32Error = WILC_TimerCreate(&(hDuringIpTimer), clear_duringIP);
#endif
}
op_ifcs++;
#ifdef DISABLE_PWRSAVE_AND_SCAN_DURING_IP
if (op_ifcs == 0) {
PRINT_D(CORECONFIG_DBG, "destroy during ip\n");
- WILC_TimerDestroy(&hDuringIpTimer, NULL);
+ WILC_TimerDestroy(&hDuringIpTimer);
}
#endif