* @version 1.0
*/
struct host_if_msg {
- u16 u16MsgId; /*!< Message ID */
+ u16 id; /*!< Message ID */
tuniHostIFmsgBody uniHostIFmsgBody; /*!< Message body */
tstrWILC_WFIDrv *drvHandler;
};
/* prepare the Timer Callback message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_LISTEN_TIMER_FIRED;
+ msg.id = HOST_IF_MSG_LISTEN_TIMER_FIRED;
msg.drvHandler = pstrWFIDrv;
msg.uniHostIFmsgBody.strHostIfRemainOnChan.u32ListenSessionID = pstrWFIDrv->strHostIfRemainOnChan.u32ListenSessionID;
while (1) {
wilc_mq_recv(&gMsgQHostIF, &msg, sizeof(struct host_if_msg), &u32Ret);
pstrWFIDrv = (tstrWILC_WFIDrv *)msg.drvHandler;
- if (msg.u16MsgId == HOST_IF_MSG_EXIT) {
+ if (msg.id == HOST_IF_MSG_EXIT) {
PRINT_D(GENERIC_DBG, "THREAD: Exiting HostIfThread\n");
break;
}
continue;
}
- if (msg.u16MsgId == HOST_IF_MSG_CONNECT && pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult != NULL) {
+ if (msg.id == HOST_IF_MSG_CONNECT && pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult != NULL) {
PRINT_D(HOSTINF_DBG, "Requeue connect request till scan done received\n");
wilc_mq_send(&gMsgQHostIF, &msg, sizeof(struct host_if_msg));
usleep_range(2 * 1000, 2 * 1000);
continue;
}
- switch (msg.u16MsgId) {
+ switch (msg.id) {
case HOST_IF_MSG_Q_IDLE:
Handle_wait_msg_q_empty();
break;
/* prepare the Timer Callback message */
memset(&msg, 0, sizeof(struct host_if_msg));
msg.drvHandler = pvArg;
- msg.u16MsgId = HOST_IF_MSG_SCAN_TIMER_FIRED;
+ msg.id = HOST_IF_MSG_SCAN_TIMER_FIRED;
/* send the message */
wilc_mq_send(&gMsgQHostIF, &msg, sizeof(struct host_if_msg));
/* prepare the Timer Callback message */
memset(&msg, 0, sizeof(struct host_if_msg));
msg.drvHandler = pvArg;
- msg.u16MsgId = HOST_IF_MSG_CONNECT_TIMER_FIRED;
+ msg.id = HOST_IF_MSG_CONNECT_TIMER_FIRED;
/* send the message */
wilc_mq_send(&gMsgQHostIF, &msg, sizeof(struct host_if_msg));
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WEP;
msg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = REMOVEKEY;
msg.drvHandler = hWFIDrv;
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WEP;
msg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = DEFAULTKEY;
msg.drvHandler = hWFIDrv;
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WEP;
msg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY;
msg.drvHandler = hWFIDrv;
for (i = 0; i < u8WepKeylen; i++)
PRINT_INFO(HOSTAPD_DBG, "KEY is %x\n", pu8WepKey[i]);
}
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WEP;
msg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY_AP;
msg.drvHandler = hWFIDrv;
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WPAPtk;
if (mode == AP_MODE) {
msg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY_AP;
}
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WPARxGtk;
msg.drvHandler = hWFIDrv;
/* prepare the Key Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_KEY;
+ msg.id = HOST_IF_MSG_KEY;
msg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = PMKSA;
msg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY;
msg.drvHandler = hWFIDrv;
/* prepare the Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_GET_MAC_ADDRESS;
+ msg.id = HOST_IF_MSG_GET_MAC_ADDRESS;
msg.uniHostIFmsgBody.strHostIfGetMacAddress.u8MacAddress = pu8MacAddress;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare setting mac address message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_SET_MAC_ADDRESS;
+ msg.id = HOST_IF_MSG_SET_MAC_ADDRESS;
memcpy(msg.uniHostIFmsgBody.strHostIfSetMacAddress.u8MacAddress, pu8MacAddress, ETH_ALEN);
msg.drvHandler = hWFIDrv;
/* prepare the Connect Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_CONNECT;
+ msg.id = HOST_IF_MSG_CONNECT;
msg.uniHostIFmsgBody.strHostIFconnectAttr.u8security = u8security;
msg.uniHostIFmsgBody.strHostIFconnectAttr.tenuAuth_type = tenuAuth_type;
return s32Error;
}
- msg.u16MsgId = HOST_IF_MSG_FLUSH_CONNECT;
+ msg.id = HOST_IF_MSG_FLUSH_CONNECT;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare the Disconnect Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_DISCONNECT;
+ msg.id = HOST_IF_MSG_DISCONNECT;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare the set channel message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_SET_CHANNEL;
+ msg.id = HOST_IF_MSG_SET_CHANNEL;
msg.uniHostIFmsgBody.strHostIFSetChan.u8SetChan = u8ChNum;
msg.drvHandler = hWFIDrv;
/* prepare the set driver handler message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_Q_IDLE;
+ msg.id = HOST_IF_MSG_Q_IDLE;
s32Error = wilc_mq_send(&gMsgQHostIF, &msg, sizeof(struct host_if_msg));
if (s32Error) {
PRINT_ER("wilc mq send fail\n");
/* prepare the set driver handler message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_SET_WFIDRV_HANDLER;
+ msg.id = HOST_IF_MSG_SET_WFIDRV_HANDLER;
msg.uniHostIFmsgBody.strHostIfSetDrvHandler.u32Address = get_id_from_handler(u32address);
msg.drvHandler = u32address;
/* prepare the set driver handler message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_SET_OPERATION_MODE;
+ msg.id = HOST_IF_MSG_SET_OPERATION_MODE;
msg.uniHostIFmsgBody.strHostIfSetOperationMode.u32Mode = u32mode;
msg.drvHandler = hWFIDrv;
/* prepare the Get Channel Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_GET_CHNL;
+ msg.id = HOST_IF_MSG_GET_CHNL;
msg.drvHandler = hWFIDrv;
/* send the message */
memcpy(msg.uniHostIFmsgBody.strHostIfStaInactiveT.mac,
mac, ETH_ALEN);
- msg.u16MsgId = HOST_IF_MSG_GET_INACTIVETIME;
+ msg.id = HOST_IF_MSG_GET_INACTIVETIME;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare the Get RSSI Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_GET_RSSI;
+ msg.id = HOST_IF_MSG_GET_RSSI;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare the Get LINKSPEED Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_GET_LINKSPEED;
+ msg.id = HOST_IF_MSG_GET_LINKSPEED;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare the Get RSSI Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_GET_STATISTICS;
+ msg.id = HOST_IF_MSG_GET_STATISTICS;
msg.uniHostIFmsgBody.pUserData = (char *)pstrStatistics;
msg.drvHandler = hWFIDrv;
/* send the message */
/* prepare the Scan Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_SCAN;
+ msg.id = HOST_IF_MSG_SCAN;
if (pstrHiddenNetwork != NULL) {
msg.uniHostIFmsgBody.strHostIFscanAttr.strHiddenNetwork.pstrHiddenNetworkInfo = pstrHiddenNetwork->pstrHiddenNetworkInfo;
}
/* prepare the WiphyParams Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_CFG_PARAMS;
+ msg.id = HOST_IF_MSG_CFG_PARAMS;
msg.uniHostIFmsgBody.strHostIFCfgParamAttr.pstrCfgParamVal = *pstrCfgParamVal;
msg.drvHandler = hWFIDrv;
/* prepare the Get RSSI Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_GET_RSSI;
+ msg.id = HOST_IF_MSG_GET_RSSI;
msg.drvHandler = pstrWFIDrv;
/* send the message */
PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
/* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
}
- msg.u16MsgId = HOST_IF_MSG_EXIT;
+ msg.id = HOST_IF_MSG_EXIT;
msg.drvHandler = hWFIDrv;
/* prepare the Asynchronous Network Info message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_RCVD_NTWRK_INFO;
+ msg.id = HOST_IF_MSG_RCVD_NTWRK_INFO;
msg.drvHandler = pstrWFIDrv;
msg.uniHostIFmsgBody.strRcvdNetworkInfo.u32Length = u32Length;
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_RCVD_GNRL_ASYNC_INFO;
+ msg.id = HOST_IF_MSG_RCVD_GNRL_ASYNC_INFO;
msg.drvHandler = pstrWFIDrv;
/* prepare theScan Done message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_RCVD_SCAN_COMPLETE;
+ msg.id = HOST_IF_MSG_RCVD_SCAN_COMPLETE;
msg.drvHandler = pstrWFIDrv;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_REMAIN_ON_CHAN;
+ msg.id = HOST_IF_MSG_REMAIN_ON_CHAN;
msg.uniHostIFmsgBody.strHostIfRemainOnChan.u16Channel = chan;
msg.uniHostIFmsgBody.strHostIfRemainOnChan.pRemainOnChanExpired = RemainOnChanExpired;
msg.uniHostIFmsgBody.strHostIfRemainOnChan.pRemainOnChanReady = RemainOnChanReady;
/* prepare the timer fire Message */
memset(&msg, 0, sizeof(struct host_if_msg));
- msg.u16MsgId = HOST_IF_MSG_LISTEN_TIMER_FIRED;
+ msg.id = HOST_IF_MSG_LISTEN_TIMER_FIRED;
msg.drvHandler = hWFIDrv;
msg.uniHostIFmsgBody.strHostIfRemainOnChan.u32ListenSessionID = u32SessionID;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_REGISTER_FRAME;
+ msg.id = HOST_IF_MSG_REGISTER_FRAME;
switch (u16FrameType) {
case ACTION:
PRINT_D(HOSTINF_DBG, "ACTION\n");
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_ADD_BEACON;
+ msg.id = HOST_IF_MSG_ADD_BEACON;
msg.drvHandler = hWFIDrv;
pstrSetBeaconParam->u32Interval = u32Interval;
pstrSetBeaconParam->u32DTIMPeriod = u32DTIMPeriod;
}
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_DEL_BEACON;
+ msg.id = HOST_IF_MSG_DEL_BEACON;
msg.drvHandler = hWFIDrv;
PRINT_D(HOSTINF_DBG, "Setting deleting beacon message queue params\n");
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_ADD_STATION;
+ msg.id = HOST_IF_MSG_ADD_STATION;
msg.drvHandler = hWFIDrv;
memcpy(pstrAddStationMsg, pstrStaParams, sizeof(tstrWILC_AddStaParam));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_DEL_STATION;
+ msg.id = HOST_IF_MSG_DEL_STATION;
msg.drvHandler = hWFIDrv;
if (pu8MacAddr == NULL)
PRINT_D(HOSTINF_DBG, "Setting deauthenticating station message queue params\n");
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_DEL_ALL_STA;
+ msg.id = HOST_IF_MSG_DEL_ALL_STA;
msg.drvHandler = hWFIDrv;
/* Handling situation of deauthenticing all associated stations*/
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_EDIT_STATION;
+ msg.id = HOST_IF_MSG_EDIT_STATION;
msg.drvHandler = hWFIDrv;
memcpy(pstrAddStationMsg, pstrStaParams, sizeof(tstrWILC_AddStaParam));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_POWER_MGMT;
+ msg.id = HOST_IF_MSG_POWER_MGMT;
msg.drvHandler = hWFIDrv;
pstrPowerMgmtParam->bIsEnabled = bIsEnabled;
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_SET_MULTICAST_FILTER;
+ msg.id = HOST_IF_MSG_SET_MULTICAST_FILTER;
msg.drvHandler = hWFIDrv;
pstrMulticastFilterParam->bIsEnabled = bIsEnabled;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_ADD_BA_SESSION;
+ msg.id = HOST_IF_MSG_ADD_BA_SESSION;
memcpy(pBASessionInfo->au8Bssid, pBSSID, ETH_ALEN);
pBASessionInfo->u8Ted = TID;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_DEL_BA_SESSION;
+ msg.id = HOST_IF_MSG_DEL_BA_SESSION;
memcpy(pBASessionInfo->au8Bssid, pBSSID, ETH_ALEN);
pBASessionInfo->u8Ted = TID;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_DEL_ALL_RX_BA_SESSIONS;
+ msg.id = HOST_IF_MSG_DEL_ALL_RX_BA_SESSIONS;
memcpy(pBASessionInfo->au8Bssid, pBSSID, ETH_ALEN);
pBASessionInfo->u8Ted = TID;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_SET_IPADDRESS;
+ msg.id = HOST_IF_MSG_SET_IPADDRESS;
msg.uniHostIFmsgBody.strHostIfSetIP.au8IPAddr = u16ipadd;
msg.drvHandler = hWFIDrv;
memset(&msg, 0, sizeof(struct host_if_msg));
/* prepare the WiphyParams Message */
- msg.u16MsgId = HOST_IF_MSG_GET_IPADDRESS;
+ msg.id = HOST_IF_MSG_GET_IPADDRESS;
msg.uniHostIFmsgBody.strHostIfSetIP.au8IPAddr = u16ipadd;
msg.drvHandler = hWFIDrv;