staging: wilc1000: fix typos in PRINT_ERR()
[pandora-kernel.git] / drivers / staging / wilc1000 / host_interface.c
index 17ab5cd..1915fc6 100644 (file)
@@ -1,6 +1,4 @@
 #include "host_interface.h"
-#include "wilc_oswrapper.h"
-#include "itypes.h"
 #include "coreconfigurator.h"
 
 extern s32 TransportInit(void);
@@ -19,53 +17,52 @@ extern u8 g_wilc_initialized;
 /*****************************************************************************/
 
 /* Message types of the Host IF Message Queue*/
-#define HOST_IF_MSG_SCAN                                       ((u16)0)
-#define HOST_IF_MSG_CONNECT                                    ((u16)1)
-#define HOST_IF_MSG_RCVD_GNRL_ASYNC_INFO       ((u16)2)
-#define HOST_IF_MSG_KEY                                                ((u16)3)
-#define HOST_IF_MSG_RCVD_NTWRK_INFO                    ((u16)4)
-#define HOST_IF_MSG_RCVD_SCAN_COMPLETE         ((u16)5)
-#define HOST_IF_MSG_CFG_PARAMS                         ((u16)6)
-#define HOST_IF_MSG_SET_CHANNEL                                ((u16)7)
-#define HOST_IF_MSG_DISCONNECT                         ((u16)8)
-#define HOST_IF_MSG_GET_RSSI                           ((u16)9)
-#define HOST_IF_MSG_GET_CHNL                           ((u16)10)
-#define HOST_IF_MSG_ADD_BEACON                         ((u16)11)
-#define HOST_IF_MSG_DEL_BEACON                         ((u16)12)
-#define HOST_IF_MSG_ADD_STATION                                ((u16)13)
-#define HOST_IF_MSG_DEL_STATION                                ((u16)14)
-#define HOST_IF_MSG_EDIT_STATION                       ((u16)15)
-#define HOST_IF_MSG_SCAN_TIMER_FIRED                   ((u16)16)
-#define HOST_IF_MSG_CONNECT_TIMER_FIRED                ((u16)17)
-#define HOST_IF_MSG_POWER_MGMT                         ((u16)18)
-#define HOST_IF_MSG_GET_INACTIVETIME                   ((u16)19)
-#define HOST_IF_MSG_REMAIN_ON_CHAN                     ((u16)20)
-#define  HOST_IF_MSG_REGISTER_FRAME                    ((u16)21)
-#define HOST_IF_MSG_LISTEN_TIMER_FIRED     ((u16)22)
-#define HOST_IF_MSG_GET_LINKSPEED                              ((u16)23)
-#define HOST_IF_MSG_SET_WFIDRV_HANDLER         ((u16)24)
-#define HOST_IF_MSG_SET_MAC_ADDRESS            ((u16)25)
-#define HOST_IF_MSG_GET_MAC_ADDRESS            ((u16)26)
-#define HOST_IF_MSG_SET_OPERATION_MODE         ((u16)27)
-#define HOST_IF_MSG_SET_IPADDRESS                      ((u16)28)
-#define HOST_IF_MSG_GET_IPADDRESS                      ((u16)29)
-#define HOST_IF_MSG_FLUSH_CONNECT                      ((u16)30)
-#define HOST_IF_MSG_GET_STATISTICS                             ((u16)31)
-#define HOST_IF_MSG_SET_MULTICAST_FILTER               ((u16)32)
-#define HOST_IF_MSG_ADD_BA_SESSION             ((u16)33)
-#define HOST_IF_MSG_DEL_BA_SESSION             ((u16)34)
-#define HOST_IF_MSG_Q_IDLE             ((u16)35)
-#define HOST_IF_MSG_DEL_ALL_STA  ((u16)36)
-#define HOST_IF_MSG_DEL_ALL_RX_BA_SESSIONS             ((u16)34)
-
-#define HOST_IF_MSG_EXIT                                       ((u16)100)
-
-#define HOST_IF_SCAN_TIMEOUT           4000
-#define HOST_IF_CONNECT_TIMEOUT        9500
-
-#define BA_SESSION_DEFAULT_BUFFER_SIZE 16
-#define BA_SESSION_DEFAULT_TIMEOUT             1000
-#define BLOCK_ACK_REQ_SIZE 0x14
+#define HOST_IF_MSG_SCAN                        0
+#define HOST_IF_MSG_CONNECT                     1
+#define HOST_IF_MSG_RCVD_GNRL_ASYNC_INFO        2
+#define HOST_IF_MSG_KEY                         3
+#define HOST_IF_MSG_RCVD_NTWRK_INFO             4
+#define HOST_IF_MSG_RCVD_SCAN_COMPLETE          5
+#define HOST_IF_MSG_CFG_PARAMS                  6
+#define HOST_IF_MSG_SET_CHANNEL                 7
+#define HOST_IF_MSG_DISCONNECT                  8
+#define HOST_IF_MSG_GET_RSSI                    9
+#define HOST_IF_MSG_GET_CHNL                    10
+#define HOST_IF_MSG_ADD_BEACON                  11
+#define HOST_IF_MSG_DEL_BEACON                  12
+#define HOST_IF_MSG_ADD_STATION                 13
+#define HOST_IF_MSG_DEL_STATION                 14
+#define HOST_IF_MSG_EDIT_STATION                15
+#define HOST_IF_MSG_SCAN_TIMER_FIRED            16
+#define HOST_IF_MSG_CONNECT_TIMER_FIRED         17
+#define HOST_IF_MSG_POWER_MGMT                  18
+#define HOST_IF_MSG_GET_INACTIVETIME            19
+#define HOST_IF_MSG_REMAIN_ON_CHAN              20
+#define HOST_IF_MSG_REGISTER_FRAME              21
+#define HOST_IF_MSG_LISTEN_TIMER_FIRED          22
+#define HOST_IF_MSG_GET_LINKSPEED               23
+#define HOST_IF_MSG_SET_WFIDRV_HANDLER          24
+#define HOST_IF_MSG_SET_MAC_ADDRESS             25
+#define HOST_IF_MSG_GET_MAC_ADDRESS             26
+#define HOST_IF_MSG_SET_OPERATION_MODE          27
+#define HOST_IF_MSG_SET_IPADDRESS               28
+#define HOST_IF_MSG_GET_IPADDRESS               29
+#define HOST_IF_MSG_FLUSH_CONNECT               30
+#define HOST_IF_MSG_GET_STATISTICS              31
+#define HOST_IF_MSG_SET_MULTICAST_FILTER        32
+#define HOST_IF_MSG_ADD_BA_SESSION              33
+#define HOST_IF_MSG_DEL_BA_SESSION              34
+#define HOST_IF_MSG_Q_IDLE                      35
+#define HOST_IF_MSG_DEL_ALL_STA                 36
+#define HOST_IF_MSG_DEL_ALL_RX_BA_SESSIONS      34
+#define HOST_IF_MSG_EXIT                        100
+
+#define HOST_IF_SCAN_TIMEOUT                    4000
+#define HOST_IF_CONNECT_TIMEOUT                 9500
+
+#define BA_SESSION_DEFAULT_BUFFER_SIZE          16
+#define BA_SESSION_DEFAULT_TIMEOUT              1000
+#define BLOCK_ACK_REQ_SIZE                      0x14
 /*****************************************************************************/
 /*                                                             Type Definitions                                                         */
 /*****************************************************************************/
@@ -453,7 +450,7 @@ typedef union _tuniHostIFmsgBody {
        tstrHostIfRemainOnChan strHostIfRemainOnChan;
        tstrHostIfRegisterFrame strHostIfRegisterFrame;
        #endif
-       WILC_Char *pUserData;
+       char *pUserData;
        tstrHostIFDelAllSta strHostIFDelAllSta;
 } tuniHostIFmsgBody;
 
@@ -475,7 +472,7 @@ typedef struct _tstrHostIFmsg {
 
 #ifdef CONNECT_DIRECT
 typedef struct _tstrWidJoinReqExt {
-       WILC_Char SSID[MAX_SSID_LEN];
+       char SSID[MAX_SSID_LEN];
        u8 u8channel;
        u8 BSSID[6];
 } tstrWidJoinReqExt;
@@ -490,7 +487,7 @@ typedef struct _tstrJoinBssParam {
        u16 beacon_period;
        u16 cap_info;
        u8 au8bssid[6];
-       WILC_Char ssid[MAX_SSID_LEN];
+       char ssid[MAX_SSID_LEN];
        u8 ssidLen;
        u8 supp_rates[MAX_RATES_SUPPORTED + 1];
        u8 ht_capable;
@@ -617,8 +614,8 @@ static s32 Handle_SetChannel(void *drvHandler, tstrHostIFSetChan *pstrHostIFSetC
        /*prepare configuration packet*/
        strWID.u16WIDid = (u16)WID_CURRENT_CHANNEL;
        strWID.enuWIDtype = WID_CHAR;
-       strWID.ps8WidVal = (WILC_Char *)&(pstrHostIFSetChan->u8SetChan);
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.ps8WidVal = (char *)&(pstrHostIFSetChan->u8SetChan);
+       strWID.s32ValueSize = sizeof(char);
 
        PRINT_D(HOSTINF_DBG, "Setting channel\n");
        /*Sending Cfg*/
@@ -662,9 +659,8 @@ static s32 Handle_SetWfiDrvHandler(tstrHostIfSetDrvHandler *pstrHostIfSetDrvHand
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv);
 
 
-       if ((pstrHostIfSetDrvHandler->u32Address) == (u32)NULL) {
+       if ((pstrHostIfSetDrvHandler->u32Address) == (u32)NULL)
                up(&hSemDeinitDrvHandle);
-       }
 
 
        if (s32Error) {
@@ -703,14 +699,13 @@ static s32 Handle_SetOperationMode(void *drvHandler, tstrHostIfSetOperationMode
        strWID.s32ValueSize = sizeof(u32);
 
        /*Sending Cfg*/
-       PRINT_INFO(HOSTINF_DBG, "pstrWFIDrv= %p \n", pstrWFIDrv);
+       PRINT_INFO(HOSTINF_DBG, "pstrWFIDrv= %p\n", pstrWFIDrv);
 
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv);
 
 
-       if ((pstrHostIfSetOperationMode->u32Mode) == (u32)NULL) {
+       if ((pstrHostIfSetOperationMode->u32Mode) == (u32)NULL)
                up(&hSemDeinitDrvHandle);
-       }
 
 
        if (s32Error) {
@@ -745,7 +740,7 @@ s32 Handle_set_IPAddress(void *drvHandler, u8 *pu8IPAddr, u8 idx)
        if (pu8IPAddr[0] < 192)
                pu8IPAddr[0] = 0;
 
-       PRINT_INFO(HOSTINF_DBG, "Indx = %d, Handling set  IP = %d.%d.%d.%d \n", idx, pu8IPAddr[0], pu8IPAddr[1], pu8IPAddr[2], pu8IPAddr[3]);
+       PRINT_INFO(HOSTINF_DBG, "Indx = %d, Handling set  IP = %d.%d.%d.%d\n", idx, pu8IPAddr[0], pu8IPAddr[1], pu8IPAddr[2], pu8IPAddr[3]);
 
        WILC_memcpy(gs8SetIP[idx], pu8IPAddr, IP_ALEN);
 
@@ -815,7 +810,7 @@ s32 Handle_get_IPAddress(void *drvHandler, u8 *pu8IPAddr, u8 idx)
                PRINT_ER("Failed to get IP address\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_STATE);
        } else {
-               PRINT_INFO(HOSTINF_DBG, "IP address retrieved:: u8IfIdx = %d \n", idx);
+               PRINT_INFO(HOSTINF_DBG, "IP address retrieved:: u8IfIdx = %d\n", idx);
                PRINT_INFO(HOSTINF_DBG, "%d.%d.%d.%d\n", gs8GetIP[idx][0], gs8GetIP[idx][1], gs8GetIP[idx][2], gs8GetIP[idx][3]);
                PRINT_INFO(HOSTINF_DBG, "\n");
        }
@@ -846,6 +841,7 @@ static s32 Handle_SetMacAddress(void *drvHandler, tstrHostIfSetMacAddress *pstrH
        tstrWID strWID;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
        u8 *mac_buf = (u8 *)WILC_MALLOC(ETH_ALEN);
+
        if (mac_buf == NULL) {
                PRINT_ER("No buffer to send mac address\n");
                return WILC_FAIL;
@@ -945,7 +941,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_BSS_TYPE;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.bss_type;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.bss_type = (u8)strHostIFCfgParamAttr->pstrCfgParamVal.bss_type;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -963,7 +959,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_AUTH_TYPE;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.auth_type;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.auth_type = (u8)strHostIFCfgParamAttr->pstrCfgParamVal.auth_type;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -995,7 +991,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_POWER_MANAGEMENT;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.power_mgmt_mode;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.power_mgmt_mode = (u8)strHostIFCfgParamAttr->pstrCfgParamVal.power_mgmt_mode;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -1065,7 +1061,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_PREAMBLE;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.preamble_type;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.preamble_type = strHostIFCfgParamAttr->pstrCfgParamVal.preamble_type;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -1077,7 +1073,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_SHORT_SLOT_ALLOWED;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.short_slot_allowed;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.short_slot_allowed = (u8)strHostIFCfgParamAttr->pstrCfgParamVal.short_slot_allowed;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -1093,7 +1089,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_11N_TXOP_PROT_DISABLE;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.txop_prot_disabled;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.txop_prot_disabled = (u8)strHostIFCfgParamAttr->pstrCfgParamVal.txop_prot_disabled;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -1119,7 +1115,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_DTIM_PERIOD;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.dtim_period;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.dtim_period = strHostIFCfgParamAttr->pstrCfgParamVal.dtim_period;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -1136,7 +1132,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
                        strWIDList[u8WidCnt].u16WIDid = WID_SITE_SURVEY;
                        strWIDList[u8WidCnt].ps8WidVal = (s8 *)&strHostIFCfgParamAttr->pstrCfgParamVal.site_survey_enabled;
                        strWIDList[u8WidCnt].enuWIDtype = WID_CHAR;
-                       strWIDList[u8WidCnt].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[u8WidCnt].s32ValueSize = sizeof(char);
                        pstrWFIDrv->strCfgValues.site_survey_enabled = (u8)strHostIFCfgParamAttr->pstrCfgParamVal.site_survey_enabled;
                } else {
                        WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
@@ -1207,10 +1203,9 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
        }
        s32Error = SendConfigPkt(SET_CFG, strWIDList, u8WidCnt, false, (u32)pstrWFIDrv);
 
-       if (s32Error) {
+       if (s32Error)
                PRINT_ER("Error in setting CFG params\n");
 
-       }
        WILC_CATCH(s32Error)
        {
        }
@@ -1231,6 +1226,7 @@ static s32 Handle_CfgParam(void *drvHandler, tstrHostIFCfgParamAttr *strHostIFCf
 static s32 Handle_wait_msg_q_empty(void)
 {
        s32 s32Error = WILC_SUCCESS;
+
        g_wilc_initialized = 0;
        up(&hWaitResponse);
        return s32Error;
@@ -1257,19 +1253,12 @@ static s32 Handle_Scan(void *drvHandler, tstrHostIFscanAttr *pstrHostIFscanAttr)
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *) drvHandler;
 
        PRINT_D(HOSTINF_DBG, "Setting SCAN params\n");
-       PRINT_D(HOSTINF_DBG, "Scanning: In [%d] state \n", pstrWFIDrv->enuHostIFstate);
+       PRINT_D(HOSTINF_DBG, "Scanning: In [%d] state\n", pstrWFIDrv->enuHostIFstate);
 
        pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult = pstrHostIFscanAttr->pfScanResult;
        pstrWFIDrv->strWILC_UsrScanReq.u32UserScanPvoid = pstrHostIFscanAttr->pvUserArg;
 
        #ifdef WILC_P2P
-       #if 0
-       if (pstrWFIDrv->enuHostIFstate == HOST_IF_P2P_LISTEN || (pstrWFIDrv->enuHostIFstate == HOST_IF_CONNECTED && pstrWFIDrv->u8P2PConnect)) {
-               PRINT_INFO(GENERIC_DBG, "Busy: State: %d\n", pstrWFIDrv->enuHostIFstate);
-               PRINT_INFO(GENERIC_DBG, "Current Jiffies: %lu Timeout:%llu\n", jiffies, pstrWFIDrv->u64P2p_MgmtTimeout);
-               WILC_ERRORREPORT(s32Error, WILC_BUSY);
-       }
-       #endif
        #endif
 
        if ((pstrWFIDrv->enuHostIFstate >= HOST_IF_SCANNING) && (pstrWFIDrv->enuHostIFstate < HOST_IF_CONNECTED)) {
@@ -1294,9 +1283,8 @@ static s32 Handle_Scan(void *drvHandler, tstrHostIFscanAttr *pstrHostIFscanAttr)
        strWIDList[u32WidsCount].u16WIDid = (u16)WID_SSID_PROBE_REQ;
        strWIDList[u32WidsCount].enuWIDtype = WID_STR;
 
-       for (i = 0; i < pstrHostIFscanAttr->strHiddenNetwork.u8ssidnum; i++) {
+       for (i = 0; i < pstrHostIFscanAttr->strHiddenNetwork.u8ssidnum; i++)
                valuesize += ((pstrHostIFscanAttr->strHiddenNetwork.pstrHiddenNetworkInfo[i].u8ssidlen) + 1);
-       }
        pu8HdnNtwrksWidVal = WILC_MALLOC(valuesize + 1);
        strWIDList[u32WidsCount].ps8WidVal = pu8HdnNtwrksWidVal;
        if (strWIDList[u32WidsCount].ps8WidVal != NULL) {
@@ -1333,7 +1321,7 @@ static s32 Handle_Scan(void *drvHandler, tstrHostIFscanAttr *pstrHostIFscanAttr)
        /*Scan Type*/
        strWIDList[u32WidsCount].u16WIDid = WID_SCAN_TYPE;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(pstrHostIFscanAttr->u8ScanType));
        u32WidsCount++;
 
@@ -1346,9 +1334,8 @@ static s32 Handle_Scan(void *drvHandler, tstrHostIFscanAttr *pstrHostIFscanAttr)
                int i;
 
                for (i = 0; i < pstrHostIFscanAttr->u8ChnlListLen; i++) {
-                       if (pstrHostIFscanAttr->pu8ChnlFreqList[i] > 0) {
+                       if (pstrHostIFscanAttr->pu8ChnlFreqList[i] > 0)
                                pstrHostIFscanAttr->pu8ChnlFreqList[i] = pstrHostIFscanAttr->pu8ChnlFreqList[i] - 1;
-                       }
                }
        }
 
@@ -1359,7 +1346,7 @@ static s32 Handle_Scan(void *drvHandler, tstrHostIFscanAttr *pstrHostIFscanAttr)
        /*Scan Request*/
        strWIDList[u32WidsCount].u16WIDid = WID_START_SCAN_REQ;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(pstrHostIFscanAttr->u8ScanSource));
        u32WidsCount++;
 
@@ -1410,9 +1397,8 @@ static s32 Handle_Scan(void *drvHandler, tstrHostIFscanAttr *pstrHostIFscanAttr)
                pstrHostIFscanAttr->pu8ChnlFreqList = NULL;
        }
 
-       if (pu8HdnNtwrksWidVal != NULL) {
+       if (pu8HdnNtwrksWidVal != NULL)
                WILC_FREE(pu8HdnNtwrksWidVal);
-       }
 
        return s32Error;
 }
@@ -1447,7 +1433,7 @@ static s32 Handle_ScanDone(void *drvHandler, tenuScanEvent enuEvent)
                strWID.u16WIDid = (u16)WID_ABORT_RUNNING_SCAN;
                strWID.enuWIDtype       = WID_CHAR;
                strWID.ps8WidVal = (s8 *)&u8abort_running_scan;
-               strWID.s32ValueSize = sizeof(WILC_Char);
+               strWID.s32ValueSize = sizeof(char);
 
                /*Sending Cfg*/
                s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv);
@@ -1538,7 +1524,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                DeallocateSurveyResults(pstrSurveyResults);
        } else {
                WILC_ERRORREPORT(s32Error, WILC_FAIL);
-               PRINT_ER("ParseSurveyResults() Error(%d) \n", s32Err);
+               PRINT_ER("ParseSurveyResults() Error(%d)\n", s32Err);
        }
 
 
@@ -1569,7 +1555,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
        if (i < pstrWFIDrv->u32SurveyResultsCount) {
                u8bssDscListIndex = i;
 
-               PRINT_INFO(HOSTINF_DBG, "Connecting to network of Bss Idx %d and SSID %s and channel %d \n",
+               PRINT_INFO(HOSTINF_DBG, "Connecting to network of Bss Idx%d and SSID %s and channel%d\n",
                           u8bssDscListIndex, pstrWFIDrv->astrSurveyResults[u8bssDscListIndex].SSID,
                           pstrWFIDrv->astrSurveyResults[u8bssDscListIndex].Channel);
 
@@ -1613,7 +1599,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                }
                strWIDList[u32WidsCount].u16WIDid = (u16)WID_11I_MODE;
                strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-               strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+               strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
                strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(pstrWFIDrv->strWILC_UsrConnReq.u8security));
                u32WidsCount++;
 
@@ -1621,7 +1607,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
 
                strWIDList[u32WidsCount].u16WIDid = (u16)WID_AUTH_TYPE;
                strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-               strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+               strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
                strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&pstrWFIDrv->strWILC_UsrConnReq.tenuAuth_type);
                u32WidsCount++;
 
@@ -1636,7 +1622,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
 
                strWIDList[u32WidsCount].u16WIDid = (u16)WID_JOIN_REQ;
                strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-               strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+               strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
                strWIDList[u32WidsCount].ps8WidVal = (s8 *)&u8bssDscListIndex;
                u32WidsCount++;
 
@@ -1684,17 +1670,6 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
        }
        #endif /*WILC_PARSE_SCAN_IN_HOST*/
 
-#if 0
-       /* if we try to connect to an already connected AP then discard the request */
-       PRINT_D(GENERIC_DBG, "Bssid = %x:%x:%x:%x:%x:%x\n", (pstrHostIFconnectAttr->pu8bssid[0]), (pstrHostIFconnectAttr->pu8bssid[1]), (pstrHostIFconnectAttr->pu8bssid[2]), (pstrHostIFconnectAttr->pu8bssid[3]), (pstrHostIFconnectAttr->pu8bssid[4]), (pstrHostIFconnectAttr->pu8bssid[5]));
-       PRINT_D(GENERIC_DBG, "bssid = %x:%x:%x:%x:%x:%x\n", (u8ConnectedSSID[0]), (u8ConnectedSSID[1]), (u8ConnectedSSID[2]), (u8ConnectedSSID[3]), (u8ConnectedSSID[4]), (u8ConnectedSSID[5]));
-       if (WILC_memcmp(pstrHostIFconnectAttr->pu8bssid, u8ConnectedSSID, ETH_ALEN) == 0) {
-               PRINT_ER("Discard connect request\n");
-               s32Error = WILC_FAIL;
-               return s32Error;
-       }
-#endif
-
        if (pstrHostIFconnectAttr->pu8bssid != NULL) {
                pstrWFIDrv->strWILC_UsrConnReq.pu8bssid = (u8 *)WILC_MALLOC(6);
                WILC_memcpy(pstrWFIDrv->strWILC_UsrConnReq.pu8bssid, pstrHostIFconnectAttr->pu8bssid, 6);
@@ -1759,7 +1734,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
        }
        strWIDList[u32WidsCount].u16WIDid = (u16)WID_11I_MODE;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(pstrWFIDrv->strWILC_UsrConnReq.u8security));
        u32WidsCount++;
 
@@ -1772,7 +1747,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
 
        strWIDList[u32WidsCount].u16WIDid = (u16)WID_AUTH_TYPE;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&pstrWFIDrv->strWILC_UsrConnReq.tenuAuth_type);
        u32WidsCount++;
 
@@ -1799,9 +1774,8 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
        strWIDList[u32WidsCount].s32ValueSize = MAX_SSID_LEN + 7;
        strWIDList[u32WidsCount].ps8WidVal = WILC_MALLOC(strWIDList[u32WidsCount].s32ValueSize);
 
-       if (strWIDList[u32WidsCount].ps8WidVal == NULL) {
+       if (strWIDList[u32WidsCount].ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWIDList[u32WidsCount].ps8WidVal;
 
@@ -1816,9 +1790,8 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                PRINT_ER("Channel out of range\n");
                *(pu8CurrByte++) = 0xFF;
        }
-       if (pstrHostIFconnectAttr->pu8bssid != NULL) {
+       if (pstrHostIFconnectAttr->pu8bssid != NULL)
                WILC_memcpy(pu8CurrByte, pstrHostIFconnectAttr->pu8bssid, 6);
-       }
        pu8CurrByte += 6;
 
        /* keep the buffer at the start of the allocated pointer to use it with the free*/
@@ -1838,9 +1811,8 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                gu32FlushedJoinReqSize = strWIDList[u32WidsCount].s32ValueSize;
                gu8FlushedJoinReq = WILC_MALLOC(gu32FlushedJoinReqSize);
        }
-       if (strWIDList[u32WidsCount].ps8WidVal == NULL) {
+       if (strWIDList[u32WidsCount].ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWIDList[u32WidsCount].ps8WidVal;
 
@@ -1866,15 +1838,13 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
        PRINT_D(HOSTINF_DBG, "* Cap Info %0x*\n", (*(pu8CurrByte - 2) | ((*(pu8CurrByte - 1)) << 8)));
 
        /* sa*/
-       if (pstrHostIFconnectAttr->pu8bssid != NULL) {
+       if (pstrHostIFconnectAttr->pu8bssid != NULL)
                WILC_memcpy(pu8CurrByte, pstrHostIFconnectAttr->pu8bssid, 6);
-       }
        pu8CurrByte += 6;
 
        /* bssid*/
-       if (pstrHostIFconnectAttr->pu8bssid != NULL) {
+       if (pstrHostIFconnectAttr->pu8bssid != NULL)
                WILC_memcpy(pu8CurrByte, pstrHostIFconnectAttr->pu8bssid, 6);
-       }
        pu8CurrByte += 6;
 
        /* Beacon Period*/
@@ -2011,9 +1981,8 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                WILC_memset(&strConnectInfo, 0, sizeof(tstrConnectInfo));
 
                if (pstrHostIFconnectAttr->pfConnectResult != NULL) {
-                       if (pstrHostIFconnectAttr->pu8bssid != NULL) {
+                       if (pstrHostIFconnectAttr->pu8bssid != NULL)
                                WILC_memcpy(strConnectInfo.au8bssid, pstrHostIFconnectAttr->pu8bssid, 6);
-                       }
 
                        if (pstrHostIFconnectAttr->pu8IEs != NULL) {
                                strConnectInfo.ReqIEsLen = pstrHostIFconnectAttr->IEsLen;
@@ -2037,7 +2006,7 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                        }
 
                } else {
-                       PRINT_ER("Connect callback function pointer is NULL \n");
+                       PRINT_ER("Connect callback function pointer is NULL\n");
                }
        }
 
@@ -2060,9 +2029,8 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon
                pstrHostIFconnectAttr->pu8IEs = NULL;
        }
 
-       if (pu8CurrByte != NULL) {
+       if (pu8CurrByte != NULL)
                WILC_FREE(pu8CurrByte);
-       }
        return s32Error;
 }
 
@@ -2094,7 +2062,7 @@ static s32 Handle_FlushConnect(void *drvHandler)
 
        strWIDList[u32WidsCount].u16WIDid = (u16)WID_11I_MODE;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(gu8Flushed11iMode));
        u32WidsCount++;
 
@@ -2102,7 +2070,7 @@ static s32 Handle_FlushConnect(void *drvHandler)
 
        strWIDList[u32WidsCount].u16WIDid = (u16)WID_AUTH_TYPE;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&gu8FlushedAuthType);
        u32WidsCount++;
 
@@ -2194,7 +2162,7 @@ static s32 Handle_ConnectTimeout(void *drvHandler)
                        strConnectInfo.pu8ReqIEs = NULL;
                }
        } else {
-               PRINT_ER("Connect callback function pointer is NULL \n");
+               PRINT_ER("Connect callback function pointer is NULL\n");
        }
 
        /* Here we will notify our firmware also with the Connection failure {through sending to it Cfg packet carrying
@@ -2202,14 +2170,13 @@ static s32 Handle_ConnectTimeout(void *drvHandler)
        strWID.u16WIDid = (u16)WID_DISCONNECT;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = (s8 *)&u16DummyReasonCode;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        PRINT_D(HOSTINF_DBG, "Sending disconnect request\n");
 
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, false, (u32)pstrWFIDrv);
-       if (s32Error) {
+       if (s32Error)
                PRINT_ER("Failed to send dissconect config packet\n");
-       }
 
        /* Deallocation of the Saved Connect Request in the global Handle */
        pstrWFIDrv->strWILC_UsrConnReq.ssidLen = 0;
@@ -2334,7 +2301,7 @@ static s32 Handle_RcvdNtwrkInfo(void *drvHandler, tstrRcvdNetworkInfo *pstrRcvdN
 
                                }
                        } else {
-                               PRINT_WRN(HOSTINF_DBG, "Discovered networks exceeded max. limit \n");
+                               PRINT_WRN(HOSTINF_DBG, "Discovered networks exceeded max. limit\n");
                        }
                } else {
                        pstrNetworkInfo->bNewNetwork = false;
@@ -2392,9 +2359,9 @@ static s32 Handle_RcvdGnrlAsyncInfo(void *drvHandler, tstrRcvdGnrlAsyncInfo *pst
        tstrDisconnectNotifInfo strDisconnectNotifInfo;
        s32 s32Err = WILC_SUCCESS;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *) drvHandler;
-       if (pstrWFIDrv == NULL) {
+
+       if (pstrWFIDrv == NULL)
                PRINT_ER("Driver handler is NULL\n");
-       }
        PRINT_D(GENERIC_DBG, "Current State = %d,Received state = %d\n", pstrWFIDrv->enuHostIFstate,
                pstrRcvdGnrlAsyncInfo->pu8Buffer[7]);
 
@@ -2456,7 +2423,7 @@ static s32 Handle_RcvdGnrlAsyncInfo(void *drvHandler, tstrRcvdGnrlAsyncInfo *pst
                                        s32Err = ParseAssocRespInfo(gapu8RcvdAssocResp, u32RcvdAssocRespInfoLen,
                                                                    &pstrConnectRespInfo);
                                        if (s32Err) {
-                                               PRINT_ER("ParseAssocRespInfo() returned error %d \n", s32Err);
+                                               PRINT_ER("ParseAssocRespInfo() returned error %d\n", s32Err);
                                        } else {
                                                /* use the necessary parsed Info from the Received Association Response */
                                                strConnectInfo.u16ConnectStatus = pstrConnectRespInfo->u16ConnectStatus;
@@ -2487,7 +2454,7 @@ static s32 Handle_RcvdGnrlAsyncInfo(void *drvHandler, tstrRcvdGnrlAsyncInfo *pst
                         *   So check first the matching between the received mac status and the received status code in Asoc Resp */
                        if ((u8MacStatus == MAC_CONNECTED) &&
                            (strConnectInfo.u16ConnectStatus != SUCCESSFUL_STATUSCODE)) {
-                               PRINT_ER("Received MAC status is MAC_CONNECTED while the received status code in Asoc Resp is not SUCCESSFUL_STATUSCODE \n");
+                               PRINT_ER("Received MAC status is MAC_CONNECTED while the received status code in Asoc Resp is not SUCCESSFUL_STATUSCODE\n");
                                WILC_memset(u8ConnectedSSID, 0, ETH_ALEN);
 
                        } else if (u8MacStatus == MAC_DISCONNECTED)    {
@@ -2596,7 +2563,7 @@ static s32 Handle_RcvdGnrlAsyncInfo(void *drvHandler, tstrRcvdGnrlAsyncInfo *pst
                        WILC_memset(&strDisconnectNotifInfo, 0, sizeof(tstrDisconnectNotifInfo));
 
                        if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult) {
-                               PRINT_D(HOSTINF_DBG, "\n\n<< Abort the running OBSS Scan >> \n\n");
+                               PRINT_D(HOSTINF_DBG, "\n\n<< Abort the running OBSS Scan >>\n\n");
                                WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
                                Handle_ScanDone((void *)pstrWFIDrv, SCAN_EVENT_ABORTED);
                        }
@@ -2619,7 +2586,7 @@ static s32 Handle_RcvdGnrlAsyncInfo(void *drvHandler, tstrRcvdGnrlAsyncInfo *pst
                                                                                   pstrWFIDrv->strWILC_UsrConnReq.u32UserConnectPvoid);
 
                        } else {
-                               PRINT_ER("Connect result callback function is NULL \n");
+                               PRINT_ER("Connect result callback function is NULL\n");
                        }
 
                        WILC_memset(pstrWFIDrv->au8AssociatedBSSID, 0, ETH_ALEN);
@@ -2672,13 +2639,12 @@ static s32 Handle_RcvdGnrlAsyncInfo(void *drvHandler, tstrRcvdGnrlAsyncInfo *pst
                } else if ((u8MacStatus == MAC_DISCONNECTED) &&
                           (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult != NULL)) {
                        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");
+                       PRINT_D(HOSTINF_DBG, "\n\n<< Abort the running Scan >>\n\n");
                        /*Abort the running scan*/
                        WILC_TimerStop(&(pstrWFIDrv->hScanTimer), NULL);
-                       if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult) {
+                       if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult)
                                Handle_ScanDone((void *)pstrWFIDrv, SCAN_EVENT_ABORTED);
 
-                       }
                }
 
        }
@@ -2732,19 +2698,19 @@ static int Handle_Key(void *drvHandler, tstrHostIFkeyAttr *pstrHostIFkeyAttr)
                        PRINT_D(GENERIC_DBG, "ID Hostint is %d\n", (pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwepAttr.u8Wepidx));
                        strWIDList[0].u16WIDid = (u16)WID_11I_MODE;
                        strWIDList[0].enuWIDtype = WID_CHAR;
-                       strWIDList[0].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[0].s32ValueSize = sizeof(char);
                        strWIDList[0].ps8WidVal = (s8 *)(&(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwepAttr.u8mode));
 
                        strWIDList[1].u16WIDid     = WID_AUTH_TYPE;
                        strWIDList[1].enuWIDtype  = WID_CHAR;
-                       strWIDList[1].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[1].s32ValueSize = sizeof(char);
                        strWIDList[1].ps8WidVal = (s8 *)(&(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwepAttr.tenuAuth_type));
 
                        strWIDList[2].u16WIDid  = (u16)WID_KEY_ID;
                        strWIDList[2].enuWIDtype        = WID_CHAR;
 
                        strWIDList[2].ps8WidVal = (s8 *)(&(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwepAttr.u8Wepidx));
-                       strWIDList[2].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[2].s32ValueSize = sizeof(char);
 
 
                        pu8keybuf = (u8 *)WILC_MALLOC(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwepAttr.u8WepKeylen);
@@ -2812,7 +2778,7 @@ static int Handle_Key(void *drvHandler, tstrHostIFkeyAttr *pstrHostIFkeyAttr)
                        strWID.u16WIDid = (u16)WID_KEY_ID;
                        strWID.enuWIDtype       = WID_CHAR;
                        strWID.ps8WidVal        = (s8 *)(&(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwepAttr.u8Wepidx));
-                       strWID.s32ValueSize = sizeof(WILC_Char);
+                       strWID.s32ValueSize = sizeof(char);
 
                        PRINT_D(HOSTINF_DBG, "Setting default key index\n");
 
@@ -2854,7 +2820,7 @@ static int Handle_Key(void *drvHandler, tstrHostIFkeyAttr *pstrHostIFkeyAttr)
                        /* pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwpaAttr.u8Ciphermode =  0X51; */
                        strWIDList[0].u16WIDid = (u16)WID_11I_MODE;
                        strWIDList[0].enuWIDtype = WID_CHAR;
-                       strWIDList[0].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[0].s32ValueSize = sizeof(char);
                        strWIDList[0].ps8WidVal = (s8 *)(&(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwpaAttr.u8Ciphermode));
 
                        strWIDList[1].u16WIDid  = (u16)WID_ADD_RX_GTK;
@@ -2893,7 +2859,7 @@ static int Handle_Key(void *drvHandler, tstrHostIFkeyAttr *pstrHostIFkeyAttr)
                        if (pstrWFIDrv->enuHostIFstate == HOST_IF_CONNECTED) {
                                WILC_memcpy(pu8keybuf, pstrWFIDrv->au8AssociatedBSSID, ETH_ALEN);
                        } else {
-                               PRINT_ER("Couldn't handle WPARxGtk while enuHostIFstate is not HOST_IF_CONNECTED \n");
+                               PRINT_ER("Couldn't handle WPARxGtk while enuHostIFstate is not HOST_IF_CONNECTED\n");
                        }
 
                        WILC_memcpy(pu8keybuf + 6, pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwpaAttr.pu8seq, 8);
@@ -2958,7 +2924,7 @@ _WPARxGtk_end_case_:
 
                        strWIDList[0].u16WIDid = (u16)WID_11I_MODE;
                        strWIDList[0].enuWIDtype = WID_CHAR;
-                       strWIDList[0].s32ValueSize = sizeof(WILC_Char);
+                       strWIDList[0].s32ValueSize = sizeof(char);
                        strWIDList[0].ps8WidVal = (s8 *)(&(pstrHostIFkeyAttr->uniHostIFkeyAttr.strHostIFwpaAttr.u8Ciphermode));
 
                        strWIDList[1].u16WIDid  = (u16)WID_ADD_PTK;
@@ -3081,7 +3047,7 @@ static void Handle_Disconnect(void *drvHandler)
        strWID.u16WIDid = (u16)WID_DISCONNECT;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = (s8 *)&u16DummyReasonCode;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
 
 
@@ -3129,7 +3095,7 @@ static void Handle_Disconnect(void *drvHandler)
                        pstrWFIDrv->strWILC_UsrConnReq.pfUserConnectResult(CONN_DISCONN_EVENT_DISCONN_NOTIF, NULL,
                                                                           0, &strDisconnectNotifInfo, pstrWFIDrv->strWILC_UsrConnReq.u32UserConnectPvoid);
                } else {
-                       PRINT_ER("strWILC_UsrConnReq.pfUserConnectResult = NULL \n");
+                       PRINT_ER("strWILC_UsrConnReq.pfUserConnectResult = NULL\n");
                }
 
                gbScanWhileConnected = false;
@@ -3206,7 +3172,7 @@ static s32 Switch_Log_Terminal(void *drvHandler)
        strWID.u16WIDid = (u16)WID_LOGTerminal_Switch;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = &dummy;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv);
 
@@ -3215,7 +3181,7 @@ static s32 Switch_Log_Terminal(void *drvHandler)
                PRINT_D(HOSTINF_DBG, "Failed to switch log terminal\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_STATE);
        } else {
-               PRINT_INFO(HOSTINF_DBG, "MAC address set :: \n");
+               PRINT_INFO(HOSTINF_DBG, "MAC address set ::\n");
 
 
        }
@@ -3245,10 +3211,11 @@ static s32 Handle_GetChnl(void *drvHandler)
        tstrWID strWID;
        /* tstrWILC_WFIDrv * pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv; */
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
+
        strWID.u16WIDid = (u16)WID_CURRENT_CHANNEL;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = (s8 *)&gu8Chnl;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        PRINT_D(HOSTINF_DBG, "Getting channel value\n");
 
@@ -3291,7 +3258,7 @@ static void Handle_GetRssi(void *drvHandler)
        strWID.u16WIDid = (u16)WID_RSSI;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = &gs8Rssi;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        /*Sending Cfg*/
        PRINT_D(HOSTINF_DBG, "Getting RSSI value\n");
@@ -3323,7 +3290,7 @@ static void Handle_GetLinkspeed(void *drvHandler)
        strWID.u16WIDid = (u16)WID_LINKSPEED;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = &gs8lnkspd;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
        /*Sending Cfg*/
        PRINT_D(HOSTINF_DBG, "Getting LINKSPEED value\n");
 
@@ -3349,13 +3316,13 @@ s32 Handle_GetStatistics(void *drvHandler, tstrStatistics *pstrStatistics)
 
        strWIDList[u32WidsCount].u16WIDid = WID_LINKSPEED;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(pstrStatistics->u8LinkSpeed));
        u32WidsCount++;
 
        strWIDList[u32WidsCount].u16WIDid = WID_RSSI;
        strWIDList[u32WidsCount].enuWIDtype = WID_CHAR;
-       strWIDList[u32WidsCount].s32ValueSize = sizeof(WILC_Char);
+       strWIDList[u32WidsCount].s32ValueSize = sizeof(char);
        strWIDList[u32WidsCount].ps8WidVal = (s8 *)(&(pstrStatistics->s8RSSI));
        u32WidsCount++;
 
@@ -3478,15 +3445,15 @@ static void Handle_AddBeacon(void *drvHandler, tstrHostIFSetBeacon *pstrSetBeaco
        tstrWID strWID;
        u8 *pu8CurrByte;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
+
        PRINT_D(HOSTINF_DBG, "Adding BEACON\n");
 
        strWID.u16WIDid = (u16)WID_ADD_BEACON;
        strWID.enuWIDtype = WID_BIN;
        strWID.s32ValueSize = pstrSetBeaconParam->u32HeadLen + pstrSetBeaconParam->u32TailLen + 16;
        strWID.ps8WidVal = WILC_MALLOC(strWID.s32ValueSize);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
        *pu8CurrByte++ = (pstrSetBeaconParam->u32Interval & 0xFF);
@@ -3550,14 +3517,14 @@ static void Handle_DelBeacon(void *drvHandler, tstrHostIFDelBeacon *pstrDelBeaco
        tstrWID strWID;
        u8 *pu8CurrByte;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
+
        strWID.u16WIDid = (u16)WID_DEL_BEACON;
        strWID.enuWIDtype = WID_CHAR;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
        strWID.ps8WidVal = &gu8DelBcn;
 
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
 
@@ -3601,9 +3568,8 @@ static u32 WILC_HostIf_PackStaParam(u8 *pu8Buffer, tstrWILC_AddStaParam *pstrSta
        *pu8CurrByte++ = (pstrStationParam->u16AssocID >> 8) & 0xFF;
 
        *pu8CurrByte++ = pstrStationParam->u8NumRates;
-       if (pstrStationParam->u8NumRates > 0) {
+       if (pstrStationParam->u8NumRates > 0)
                WILC_memcpy(pu8CurrByte, pstrStationParam->pu8Rates, pstrStationParam->u8NumRates);
-       }
        pu8CurrByte += pstrStationParam->u8NumRates;
 
        *pu8CurrByte++ = pstrStationParam->bIsHTSupported;
@@ -3648,15 +3614,15 @@ static void Handle_AddStation(void *drvHandler, tstrWILC_AddStaParam *pstrStatio
        tstrWID strWID;
        u8 *pu8CurrByte;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
+
        PRINT_D(HOSTINF_DBG, "Handling add station\n");
        strWID.u16WIDid = (u16)WID_ADD_STA;
        strWID.enuWIDtype = WID_BIN;
        strWID.s32ValueSize = WILC_ADD_STA_LENGTH + pstrStationParam->u8NumRates;
 
        strWID.ps8WidVal = WILC_MALLOC(strWID.s32ValueSize);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
        pu8CurrByte += WILC_HostIf_PackStaParam(pu8CurrByte, pstrStationParam);
@@ -3688,21 +3654,22 @@ static void Handle_AddStation(void *drvHandler, tstrWILC_AddStaParam *pstrStatio
 static void Handle_DelAllSta(void *drvHandler, tstrHostIFDelAllSta *pstrDelAllStaParam)
 {
        s32 s32Error = WILC_SUCCESS;
+
        tstrWID strWID;
        u8 *pu8CurrByte;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
        u8 i;
        u8 au8Zero_Buff[6] = {0};
+
        strWID.u16WIDid = (u16)WID_DEL_ALL_STA;
        strWID.enuWIDtype = WID_STR;
        strWID.s32ValueSize = (pstrDelAllStaParam->u8Num_AssocSta * ETH_ALEN) + 1;
 
-       PRINT_D(HOSTINF_DBG, "Handling delete station \n");
+       PRINT_D(HOSTINF_DBG, "Handling delete station\n");
 
        strWID.ps8WidVal = WILC_MALLOC((pstrDelAllStaParam->u8Num_AssocSta * ETH_ALEN) + 1);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
 
@@ -3721,7 +3688,7 @@ static void Handle_DelAllSta(void *drvHandler, tstrHostIFDelAllSta *pstrDelAllSt
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv);
        if (s32Error) {
 
-               PRINT_ER("Failed to send add station config packe\n");
+               PRINT_ER("Failed to send add station config packet\n");
                WILC_ERRORREPORT(s32Error, WILC_FAIL);
        }
 
@@ -3754,12 +3721,11 @@ static void Handle_DelStation(void *drvHandler, tstrHostIFDelSta *pstrDelStaPara
        strWID.enuWIDtype = WID_BIN;
        strWID.s32ValueSize = ETH_ALEN;
 
-       PRINT_D(HOSTINF_DBG, "Handling delete station \n");
+       PRINT_D(HOSTINF_DBG, "Handling delete station\n");
 
        strWID.ps8WidVal = WILC_MALLOC(strWID.s32ValueSize);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
 
@@ -3769,7 +3735,7 @@ static void Handle_DelStation(void *drvHandler, tstrHostIFDelSta *pstrDelStaPara
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, false, (u32)pstrWFIDrv);
        if (s32Error) {
 
-               PRINT_ER("Failed to send add station config packe\n");
+               PRINT_ER("Failed to send add station config packet\n");
                WILC_ERRORREPORT(s32Error, WILC_FAIL);
        }
 
@@ -3802,9 +3768,8 @@ static void Handle_EditStation(void *drvHandler, tstrWILC_AddStaParam *pstrStati
 
        PRINT_D(HOSTINF_DBG, "Handling edit station\n");
        strWID.ps8WidVal = WILC_MALLOC(strWID.s32ValueSize);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
        pu8CurrByte += WILC_HostIf_PackStaParam(pu8CurrByte, pstrStationParam);
@@ -3879,18 +3844,16 @@ static int Handle_RemainOnChan(void *drvHandler, tstrHostIfRemainOnChan *pstrHos
        strWID.s32ValueSize = 2;
        strWID.ps8WidVal = (s8 *)WILC_MALLOC(strWID.s32ValueSize);
 
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        strWID.ps8WidVal[0] = u8remain_on_chan_flag;
        strWID.ps8WidVal[1] = (s8)pstrHostIfRemainOnChan->u16Channel;
 
        /*Sending Cfg*/
        s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv);
-       if (s32Error != WILC_SUCCESS) {
+       if (s32Error != WILC_SUCCESS)
                PRINT_ER("Failed to set remain on channel\n");
-       }
 
        WILC_CATCH(-1)
        {
@@ -3898,9 +3861,8 @@ static int Handle_RemainOnChan(void *drvHandler, tstrHostIfRemainOnChan *pstrHos
                WILC_TimerStart(&(pstrWFIDrv->hRemainOnChannel), pstrHostIfRemainOnChan->u32duration, (void *)pstrWFIDrv, NULL);
 
                /*Calling CFG ready_on_channel*/
-               if (pstrWFIDrv->strHostIfRemainOnChan.pRemainOnChanReady) {
+               if (pstrWFIDrv->strHostIfRemainOnChan.pRemainOnChanReady)
                        pstrWFIDrv->strHostIfRemainOnChan.pRemainOnChanReady(pstrWFIDrv->strHostIfRemainOnChan.pVoid);
-               }
 
                if (pstrWFIDrv->u8RemainOnChan_pendingreq)
                        pstrWFIDrv->u8RemainOnChan_pendingreq = 0;
@@ -3930,9 +3892,8 @@ static int Handle_RegisterFrame(void *drvHandler, tstrHostIfRegisterFrame *pstrH
        strWID.u16WIDid = (u16)WID_REGISTER_FRAME;
        strWID.enuWIDtype = WID_STR;
        strWID.ps8WidVal = WILC_MALLOC(sizeof(u16) + 2);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
 
@@ -3989,9 +3950,8 @@ static u32 Handle_ListenStateExpired(void *drvHandler, tstrHostIfRemainOnChan *p
                strWID.s32ValueSize = 2;
                strWID.ps8WidVal = WILC_MALLOC(strWID.s32ValueSize);
 
-               if (strWID.ps8WidVal == NULL) {
+               if (strWID.ps8WidVal == NULL)
                        PRINT_ER("Failed to allocate memory\n");
-               }
 
                strWID.ps8WidVal[0] = u8remain_on_chan_flag;
                strWID.ps8WidVal[1] = FALSE_FRMWR_CHANNEL;
@@ -4043,9 +4003,8 @@ static void ListenTimerCB(void *pvArg)
 
        /* send the message */
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -4069,6 +4028,7 @@ static void Handle_PowerManagement(void *drvHandler, tstrHostIfPowerMgmtParam *s
        tstrWID strWID;
        s8 s8PowerMode;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
+
        strWID.u16WIDid = (u16)WID_POWER_MANAGEMENT;
 
        if (strPowerMgmtParam->bIsEnabled == true)      {
@@ -4078,7 +4038,7 @@ static void Handle_PowerManagement(void *drvHandler, tstrHostIfPowerMgmtParam *s
        }
        PRINT_D(HOSTINF_DBG, "Handling power mgmt to %d\n", s8PowerMode);
        strWID.ps8WidVal = &s8PowerMode;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        PRINT_D(HOSTINF_DBG, "Handling Power Management\n");
 
@@ -4116,9 +4076,8 @@ static void Handle_SetMulticastFilter(void *drvHandler, tstrHostIFSetMulti *strH
        strWID.enuWIDtype = WID_BIN;
        strWID.s32ValueSize = sizeof(tstrHostIFSetMulti) + ((strHostIfSetMulti->u32count) * ETH_ALEN);
        strWID.ps8WidVal = WILC_MALLOC(strWID.s32ValueSize);
-       if (strWID.ps8WidVal == NULL) {
+       if (strWID.ps8WidVal == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
 
        pu8CurrByte = strWID.ps8WidVal;
        *pu8CurrByte++ = (strHostIfSetMulti->bIsEnabled & 0xFF);
@@ -4167,7 +4126,7 @@ static s32 Handle_AddBASession(void *drvHandler, tstrHostIfBASessionInfo *strHos
        char *ptr = NULL;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
 
-       PRINT_D(HOSTINF_DBG, "Opening Block Ack session with\nBSSID = %.2x:%.2x:%.2x \nTID=%d \nBufferSize == %d \nSessionTimeOut = %d\n",
+       PRINT_D(HOSTINF_DBG, "Opening Block Ack session with\nBSSID = %.2x:%.2x:%.2x\nTID=%d\nBufferSize == %d\nSessionTimeOut = %d\n",
                strHostIfBASessionInfo->au8Bssid[0],
                strHostIfBASessionInfo->au8Bssid[1],
                strHostIfBASessionInfo->au8Bssid[2],
@@ -4254,7 +4213,7 @@ static s32 Handle_DelBASession(void *drvHandler, tstrHostIfBASessionInfo *strHos
        char *ptr = NULL;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
 
-       PRINT_D(GENERIC_DBG, "Delete Block Ack session with\nBSSID = %.2x:%.2x:%.2x \nTID=%d\n",
+       PRINT_D(GENERIC_DBG, "Delete Block Ack session with\nBSSID = %.2x:%.2x:%.2x\nTID=%d\n",
                strHostIfBASessionInfo->au8Bssid[0],
                strHostIfBASessionInfo->au8Bssid[1],
                strHostIfBASessionInfo->au8Bssid[2],
@@ -4324,7 +4283,7 @@ static s32 Handle_DelAllRxBASessions(void *drvHandler, tstrHostIfBASessionInfo *
        char *ptr = NULL;
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
 
-       PRINT_D(GENERIC_DBG, "Delete Block Ack session with\nBSSID = %.2x:%.2x:%.2x \nTID=%d\n",
+       PRINT_D(GENERIC_DBG, "Delete Block Ack session with\nBSSID = %.2x:%.2x:%.2x\nTID=%d\n",
                strHostIfBASessionInfo->au8Bssid[0],
                strHostIfBASessionInfo->au8Bssid[1],
                strHostIfBASessionInfo->au8Bssid[2],
@@ -4451,9 +4410,8 @@ static int hostIFthread(void *pvArg)
 
                        /*BugID_5213*/
                        /*Allow chip sleep, only if both interfaces are not connected*/
-                       if (!linux_wlan_get_num_conn_ifcs()) {
+                       if (!linux_wlan_get_num_conn_ifcs())
                                chip_sleep_manually(INFINITE_SLEEP_TIME);
-                       }
 
                        Handle_ScanDone(strHostIFmsg.drvHandler, SCAN_EVENT_DONE);
 
@@ -4513,7 +4471,7 @@ static int hostIFthread(void *pvArg)
                        break;
 
                case HOST_IF_MSG_CONNECT_TIMER_FIRED:
-                       PRINT_D(HOSTINF_DBG, "Connect Timeout \n");
+                       PRINT_D(HOSTINF_DBG, "Connect Timeout\n");
                        Handle_ConnectTimeout(strHostIFmsg.drvHandler);
                        break;
 
@@ -4584,7 +4542,7 @@ static int hostIFthread(void *pvArg)
                        break;
 
                default:
-                       PRINT_ER("[Host Interface] undefined Received Msg ID  \n");
+                       PRINT_ER("[Host Interface] undefined Received Msg ID\n");
                        break;
                }
        }
@@ -4670,9 +4628,8 @@ s32 host_int_remove_wep_key(WILC_WFIDrvHandle hWFIDrv, u8 u8keyIdx)
        tstrHostIFmsg strHostIFmsg;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /* prepare the Remove Wep Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -4691,7 +4648,7 @@ s32 host_int_remove_wep_key(WILC_WFIDrvHandle hWFIDrv, u8 u8keyIdx)
        /* send the message */
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
        if (s32Error)
-               PRINT_ER("Error in sending message queue : Request to remove WEP key \n");
+               PRINT_ER("Error in sending message queue : Request to remove WEP key\n");
        down(&(pstrWFIDrv->hSemTestKeyBlock));
 
        WILC_CATCH(s32Error)
@@ -4720,9 +4677,8 @@ s32 host_int_set_WEPDefaultKeyID(WILC_WFIDrvHandle hWFIDrv, u8 u8Index)
        tstrHostIFmsg strHostIFmsg;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /* prepare the Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -4777,10 +4733,9 @@ s32 host_int_add_wep_key_bss_sta(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8WepKey,
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
 
-       }
 
        /* prepare the Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -4844,10 +4799,9 @@ s32 host_int_add_wep_key_bss_ap(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8WepKey,
        tstrHostIFmsg strHostIFmsg;
        u8 i;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
 
-       }
 
        /* prepare the Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -4920,15 +4874,13 @@ s32 host_int_add_ptk(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8Ptk, u8 u8PtkKeylen
        tstrHostIFmsg strHostIFmsg;
        u8 u8KeyLen = u8PtkKeylen;
        u32 i;
-       if (pstrWFIDrv == NULL) {
+
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
-       if (pu8RxMic != NULL) {
+       if (pu8RxMic != NULL)
                u8KeyLen += RX_MIC_KEY_LEN;
-       }
-       if (pu8TxMic != NULL) {
+       if (pu8TxMic != NULL)
                u8KeyLen += TX_MIC_KEY_LEN;
-       }
 
        /* prepare the Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -5023,19 +4975,16 @@ s32 host_int_add_rx_gtk(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8RxGtk, u8 u8GtkK
        tstrHostIFmsg strHostIFmsg;
        u8 u8KeyLen = u8GtkKeylen;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
        /* prepare the Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
 
-       if (pu8RxMic != NULL) {
+       if (pu8RxMic != NULL)
                u8KeyLen += RX_MIC_KEY_LEN;
-       }
-       if (pu8TxMic != NULL) {
+       if (pu8TxMic != NULL)
                u8KeyLen += TX_MIC_KEY_LEN;
-       }
        if (KeyRSC != NULL) {
                strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.
                uniHostIFkeyAttr.strHostIFwpaAttr.pu8seq = (u8 *)WILC_MALLOC(u32KeyRSClen);
@@ -5103,65 +5052,7 @@ s32 host_int_add_rx_gtk(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8RxGtk, u8 u8GtkK
        }
        return s32Error;
 }
-#if 0
-/**
- *  @brief                      host_int_add_tx_gtk
- *  @details            adds Tx GTk Key
- *  @param[in,out] handle to the wifi driver
- *  @param[in]  message containing Tx GTK Key in the following format
- *|----------------------------------------------------|
- | KeyID | Key Length | Temporal Key   | Tx Michael Key |
- ||-------|------------|--------------|----------------|
- ||1 byte |  1 byte     |   16 bytes   |         8 bytes        |
- ||----------------------------------------------------|
- *  @return             Error code indicating success/failure
- *  @note
- *  @author            zsalah
- *  @date              8 March 2012
- *  @version           1.0
- */
-s32 host_int_add_tx_gtk(WILC_WFIDrvHandle hWFIDrv, u8 u8KeyLen, u8 *pu8TxGtk, u8 u8KeyIdx)
-{
-       s32 s32Error = WILC_SUCCESS;
-       tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
-       tstrHostIFmsg strHostIFmsg;
-
-       if (pstrWFIDrv == NULL) {
-               WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
-       /* prepare the Key Message */
-       WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
-
-       strHostIFmsg.u16MsgId = HOST_IF_MSG_KEY;
-       strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.enuKeyType = WPATxGtk;
-       strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.u8KeyAction = ADDKEY;
-
-       strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.
-       uniHostIFkeyAttr.strHostIFwpaAttr.pu8key = (u8 *)WILC_MALLOC(u8KeyLen);
-
-       WILC_memcpy(strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.uniHostIFkeyAttr.strHostIFwpaAttr.pu8key,
-                   pu8TxGtk, u8KeyLen);
-
-       strHostIFmsg.uniHostIFmsgBody.strHostIFkeyAttr.uniHostIFkeyAttr.strHostIFwpaAttr.u8Keylen = u8KeyLen;
-
-       /* send the message */
-       s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error)
-               PRINT_ER("Error in sending message queue: TX GTK\n");
-
-       /* ////////////// */
-       down(&hSemTestKeyBlock);
-       WILC_Sleep(100);
-       /* /////// */
-
-       WILC_CATCH(s32Error)
-       {
-
-       }
-       return s32Error;
-}
-#endif
 /**
  *  @brief              host_int_set_pmkid_info
  *  @details    caches the pmkid valid only in BSS STA mode if External Supplicant
@@ -5190,9 +5081,8 @@ s32 host_int_set_pmkid_info(WILC_WFIDrvHandle hWFIDrv, tstrHostIFpmkidAttr *pu8P
        u32 i;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /* prepare the Key Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -5484,7 +5374,7 @@ s32 host_int_set_start_scan_req(WILC_WFIDrvHandle hWFIDrv, u8 scanSource)
        strWID.u16WIDid = (u16)WID_START_SCAN_REQ;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = (s8 *)&scanSource;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        return s32Error;
 }
@@ -5514,7 +5404,7 @@ s32 host_int_get_start_scan_req(WILC_WFIDrvHandle hWFIDrv, u8 *pu8ScanSource)
        strWID.u16WIDid = (u16)WID_START_SCAN_REQ;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = (s8 *)pu8ScanSource;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        return s32Error;
 }
@@ -5543,9 +5433,8 @@ s32 host_int_set_join_req(WILC_WFIDrvHandle hWFIDrv, u8 *pu8bssid,
        tstrHostIFmsg strHostIFmsg;
        tenuScanConnTimer enuScanConnTimer;
 
-       if (pstrWFIDrv == NULL || pfConnectResult == NULL) {
+       if (pstrWFIDrv == NULL || pfConnectResult == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        if (hWFIDrv == NULL) {
                PRINT_ER("Driver not initialized: gWFiDrvHandle = NULL\n");
@@ -5643,9 +5532,8 @@ s32 host_int_flush_join_req(WILC_WFIDrvHandle hWFIDrv)
        }
 
 
-       if (hWFIDrv  == NULL) {
+       if (hWFIDrv  == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
 
        strHostIFmsg.u16MsgId = HOST_IF_MSG_FLUSH_CONNECT;
@@ -5683,7 +5571,7 @@ s32 host_int_disconnect(WILC_WFIDrvHandle hWFIDrv, u16 u16ReasonCode)
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
 
@@ -5734,7 +5622,7 @@ s32 host_int_disconnect_station(WILC_WFIDrvHandle hWFIDrv, u8 assoc_id)
        strWID.u16WIDid = (u16)WID_DISCONNECT;
        strWID.enuWIDtype = WID_CHAR;
        strWID.ps8WidVal = (s8 *)&assoc_id;
-       strWID.s32ValueSize = sizeof(WILC_Char);
+       strWID.s32ValueSize = sizeof(char);
 
        return s32Error;
 }
@@ -5800,7 +5688,7 @@ s32 host_int_get_assoc_res_info(WILC_WFIDrvHandle hWFIDrv, u8 *pu8AssocRespInfo,
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
 
@@ -5879,9 +5767,8 @@ s32 host_int_set_mac_chnl_num(WILC_WFIDrvHandle hWFIDrv, u8 u8ChNum)
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /* prepare the set channel message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -5890,9 +5777,8 @@ s32 host_int_set_mac_chnl_num(WILC_WFIDrvHandle hWFIDrv, u8 u8ChNum)
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -5913,9 +5799,8 @@ s32 host_int_wait_msg_queue_idle(void)
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
        strHostIFmsg.u16MsgId = HOST_IF_MSG_Q_IDLE;
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -5943,9 +5828,8 @@ s32 host_int_set_wfi_drv_handler(u32 u32address)
        /* strHostIFmsg.drvHandler=hWFIDrv; */
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -5971,9 +5855,8 @@ s32 host_int_set_operation_mode(WILC_WFIDrvHandle hWFIDrv, u32 u32mode)
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -6004,7 +5887,7 @@ s32 host_int_get_host_chnl_num(WILC_WFIDrvHandle hWFIDrv, u8 *pu8ChNo)
        tstrHostIFmsg strHostIFmsg;
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
 
@@ -6051,14 +5934,14 @@ s32 host_int_test_set_int_wid(WILC_WFIDrvHandle hWFIDrv, u32 u32TestMemAddr)
 
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
 
        /*prepare configuration packet*/
        strWID.u16WIDid = (u16)WID_MEMORY_ADDRESS;
        strWID.enuWIDtype = WID_INT;
-       strWID.ps8WidVal = (WILC_Char *)&u32TestMemAddr;
+       strWID.ps8WidVal = (char *)&u32TestMemAddr;
        strWID.s32ValueSize = sizeof(u32);
 
        /*Sending Cfg*/
@@ -6097,7 +5980,7 @@ s32 host_int_get_inactive_time(WILC_WFIDrvHandle hWFIDrv, const u8 *mac, u32 *pu
        tstrHostIFmsg strHostIFmsg;
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
 
@@ -6145,7 +6028,7 @@ s32 host_int_test_get_int_wid(WILC_WFIDrvHandle hWFIDrv, u32 *pu32TestMemAddr)
 
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
 
@@ -6267,7 +6150,7 @@ s32 host_int_get_statistics(WILC_WFIDrvHandle hWFIDrv, tstrStatistics *pstrStati
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
        strHostIFmsg.u16MsgId = HOST_IF_MSG_GET_STATISTICS;
-       strHostIFmsg.uniHostIFmsgBody.pUserData = (WILC_Char *)pstrStatistics;
+       strHostIFmsg.uniHostIFmsgBody.pUserData = (char *)pstrStatistics;
        strHostIFmsg.drvHandler = hWFIDrv;
        /* send the message */
        s32Error =      WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
@@ -6308,9 +6191,8 @@ s32 host_int_scan(WILC_WFIDrvHandle hWFIDrv, u8 u8ScanSource,
        tstrHostIFmsg strHostIFmsg;
        tenuScanConnTimer enuScanConnTimer;
 
-       if (pstrWFIDrv == NULL || ScanResult == NULL)   {
+       if (pstrWFIDrv == NULL || ScanResult == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
 
        /* prepare the Scan Message */
@@ -6380,9 +6262,8 @@ s32 hif_set_cfg(WILC_WFIDrvHandle hWFIDrv, tstrCfgParamVal *pstrCfgParamVal)
        tstrHostIFmsg strHostIFmsg;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
        /* prepare the WiphyParams Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
        strHostIFmsg.u16MsgId = HOST_IF_MSG_CFG_PARAMS;
@@ -6421,7 +6302,7 @@ s32 hif_get_cfg(WILC_WFIDrvHandle hWFIDrv, u16 u16WID, u16 *pu16WID_Value)
        down(&(pstrWFIDrv->gtOsCfgValuesSem));
 
        if (pstrWFIDrv == NULL) {
-               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL \n");
+               PRINT_ER("Driver not initialized: pstrWFIDrv = NULL\n");
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
        }
        PRINT_D(HOSTINF_DBG, "Getting configuration parameters\n");
@@ -6551,6 +6432,7 @@ void host_int_send_join_leave_info_to_host
 void GetPeriodicRSSI(void *pvArg)
 {
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)pvArg;
+
        if (pstrWFIDrv == NULL) {
                PRINT_ER("Driver handler is NULL\n");
                return;
@@ -6817,18 +6699,18 @@ s32 host_int_deinit(WILC_WFIDrvHandle hWFIDrv)
        /*Destroy all timers before acquiring hSemDeinitDrvHandle*/
        /*to guarantee handling all messages befor proceeding*/
        if (WILC_TimerDestroy(&(pstrWFIDrv->hScanTimer), NULL)) {
-               PRINT_D(HOSTINF_DBG, ">> Scan timer is active \n");
+               PRINT_D(HOSTINF_DBG, ">> Scan timer is active\n");
                /* msleep(HOST_IF_SCAN_TIMEOUT+1000); */
        }
 
        if (WILC_TimerDestroy(&(pstrWFIDrv->hConnectTimer), NULL)) {
-               PRINT_D(HOSTINF_DBG, ">> Connect timer is active \n");
+               PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
                /* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
        }
 
 
        if (WILC_TimerDestroy(&(g_hPeriodicRSSI), NULL)) {
-               PRINT_D(HOSTINF_DBG, ">> Connect timer is active \n");
+               PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
                /* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
        }
 
@@ -6865,7 +6747,7 @@ s32 host_int_deinit(WILC_WFIDrvHandle hWFIDrv)
 
        if (clients_count == 1) {
                if (WILC_TimerDestroy(&g_hPeriodicRSSI, NULL)) {
-                       PRINT_D(HOSTINF_DBG, ">> Connect timer is active \n");
+                       PRINT_D(HOSTINF_DBG, ">> Connect timer is active\n");
                        /* msleep(HOST_IF_CONNECT_TIMEOUT+1000); */
                }
                strHostIFmsg.u16MsgId = HOST_IF_MSG_EXIT;
@@ -6873,9 +6755,8 @@ s32 host_int_deinit(WILC_WFIDrvHandle hWFIDrv)
 
 
                s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-               if (s32Error != WILC_SUCCESS) {
+               if (s32Error != WILC_SUCCESS)
                        PRINT_ER("Error in sending deinit's message queue message function: Error(%d)\n", s32Error);
-               }
 
                down(&hSemHostIFthrdEnd);
 
@@ -6945,9 +6826,8 @@ void NetworkInfoReceived(u8 *pu8Buffer, u32 u32Length)
 
        /* send the message */
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                PRINT_ER("Error in sending network info message queue message parameters: Error(%d)\n", s32Error);
-       }
 
 
        return;
@@ -6976,7 +6856,7 @@ void GnrlAsyncInfoReceived(u8 *pu8Buffer, u32 u32Length)
 
        drvHandler = ((pu8Buffer[u32Length - 4]) | (pu8Buffer[u32Length - 3] << 8) | (pu8Buffer[u32Length - 2] << 16) | (pu8Buffer[u32Length - 1] << 24));
        pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
-       PRINT_D(HOSTINF_DBG, "General asynchronous info packet received \n");
+       PRINT_D(HOSTINF_DBG, "General asynchronous info packet received\n");
 
 
        if (pstrWFIDrv == NULL || pstrWFIDrv == terminated_handle) {
@@ -7009,9 +6889,8 @@ void GnrlAsyncInfoReceived(u8 *pu8Buffer, u32 u32Length)
 
        /* send the message */
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                PRINT_ER("Error in sending message queue asynchronous message info: Error(%d)\n", s32Error);
-       }
 
        /*BugID_5348*/
        up(&hSemHostIntDeinit);
@@ -7033,15 +6912,15 @@ void host_int_ScanCompleteReceived(u8 *pu8Buffer, u32 u32Length)
        tstrHostIFmsg strHostIFmsg;
        u32 drvHandler;
        tstrWILC_WFIDrv *pstrWFIDrv = NULL;
+
        drvHandler = ((pu8Buffer[u32Length - 4]) | (pu8Buffer[u32Length - 3] << 8) | (pu8Buffer[u32Length - 2] << 16) | (pu8Buffer[u32Length - 1] << 24));
        pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler;
 
 
        PRINT_D(GENERIC_DBG, "Scan notification received %p\n", pstrWFIDrv);
 
-       if (pstrWFIDrv == NULL || pstrWFIDrv == terminated_handle) {
+       if (pstrWFIDrv == NULL || pstrWFIDrv == terminated_handle)
                return;
-       }
 
        /*if there is an ongoing scan request*/
        if (pstrWFIDrv->strWILC_UsrScanReq.pfUserScanResult) {
@@ -7062,9 +6941,8 @@ void host_int_ScanCompleteReceived(u8 *pu8Buffer, u32 u32Length)
 
                /* send the message */
                s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-               if (s32Error) {
+               if (s32Error)
                        PRINT_ER("Error in sending message queue scan complete parameters: Error(%d)\n", s32Error);
-               }
        }
 
 
@@ -7093,9 +6971,8 @@ s32 host_int_remain_on_channel(WILC_WFIDrvHandle hWFIDrv, u32 u32SessionID, u32
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /* prepare the remainonchan Message */
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
@@ -7111,9 +6988,8 @@ s32 host_int_remain_on_channel(WILC_WFIDrvHandle hWFIDrv, u32 u32SessionID, u32
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7142,9 +7018,8 @@ s32 host_int_ListenStateExpired(WILC_WFIDrvHandle hWFIDrv, u32 u32SessionID)
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /*Stopping remain-on-channel timer*/
        WILC_TimerStop(&(pstrWFIDrv->hRemainOnChannel), NULL);
@@ -7156,9 +7031,8 @@ s32 host_int_ListenStateExpired(WILC_WFIDrvHandle hWFIDrv, u32 u32SessionID)
        strHostIFmsg.uniHostIFmsgBody.strHostIfRemainOnChan.u32ListenSessionID = u32SessionID;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7180,9 +7054,8 @@ s32 host_int_frame_register(WILC_WFIDrvHandle hWFIDrv, u16 u16FrameType, bool bR
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7208,9 +7081,8 @@ s32 host_int_frame_register(WILC_WFIDrvHandle hWFIDrv, u16 u16FrameType, bool bR
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7244,9 +7116,8 @@ s32 host_int_add_beacon(WILC_WFIDrvHandle hWFIDrv, u32 u32Interval,
        tstrHostIFmsg strHostIFmsg;
        tstrHostIFSetBeacon *pstrSetBeaconParam = &strHostIFmsg.uniHostIFmsgBody.strHostIFSetBeacon;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7260,37 +7131,32 @@ s32 host_int_add_beacon(WILC_WFIDrvHandle hWFIDrv, u32 u32Interval,
        pstrSetBeaconParam->u32DTIMPeriod = u32DTIMPeriod;
        pstrSetBeaconParam->u32HeadLen = u32HeadLen;
        pstrSetBeaconParam->pu8Head = (u8 *)WILC_MALLOC(u32HeadLen);
-       if (pstrSetBeaconParam->pu8Head == NULL) {
+       if (pstrSetBeaconParam->pu8Head == NULL)
                WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-       }
        WILC_memcpy(pstrSetBeaconParam->pu8Head, pu8Head, u32HeadLen);
        pstrSetBeaconParam->u32TailLen = u32TailLen;
 
        /* Bug 4599 : if tail length = 0 skip allocating & copying */
        if (u32TailLen > 0) {
                pstrSetBeaconParam->pu8Tail = (u8 *)WILC_MALLOC(u32TailLen);
-               if (pstrSetBeaconParam->pu8Tail == NULL) {
+               if (pstrSetBeaconParam->pu8Tail == NULL)
                        WILC_ERRORREPORT(s32Error, WILC_NO_MEM);
-               }
                WILC_memcpy(pstrSetBeaconParam->pu8Tail, pu8Tail, u32TailLen);
        } else {
                pstrSetBeaconParam->pu8Tail = NULL;
        }
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
 
        WILC_CATCH(s32Error)
        {
-               if (pstrSetBeaconParam->pu8Head != NULL) {
+               if (pstrSetBeaconParam->pu8Head != NULL)
                        WILC_FREE(pstrSetBeaconParam->pu8Head);
-               }
 
-               if (pstrSetBeaconParam->pu8Tail != NULL) {
+               if (pstrSetBeaconParam->pu8Tail != NULL)
                        WILC_FREE(pstrSetBeaconParam->pu8Tail);
-               }
        }
 
        return s32Error;
@@ -7313,9 +7179,8 @@ s32 host_int_del_beacon(WILC_WFIDrvHandle hWFIDrv)
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        /* prepare the WiphyParams Message */
        strHostIFmsg.u16MsgId = HOST_IF_MSG_DEL_BEACON;
@@ -7349,9 +7214,8 @@ s32 host_int_add_station(WILC_WFIDrvHandle hWFIDrv, tstrWILC_AddStaParam *pstrSt
        tstrWILC_AddStaParam *pstrAddStationMsg = &strHostIFmsg.uniHostIFmsgBody.strAddStaParam;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7365,6 +7229,7 @@ s32 host_int_add_station(WILC_WFIDrvHandle hWFIDrv, tstrWILC_AddStaParam *pstrSt
        WILC_memcpy(pstrAddStationMsg, pstrStaParams, sizeof(tstrWILC_AddStaParam));
        if (pstrAddStationMsg->u8NumRates > 0) {
                u8 *rates = WILC_MALLOC(pstrAddStationMsg->u8NumRates);
+
                WILC_NULLCHECK(s32Error, rates);
 
                WILC_memcpy(rates, pstrStaParams->pu8Rates, pstrAddStationMsg->u8NumRates);
@@ -7373,9 +7238,8 @@ s32 host_int_add_station(WILC_WFIDrvHandle hWFIDrv, tstrWILC_AddStaParam *pstrSt
 
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
 
        WILC_CATCH(s32Error)
        {
@@ -7399,9 +7263,8 @@ s32 host_int_del_station(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8MacAddr)
        tstrHostIFmsg strHostIFmsg;
        tstrHostIFDelSta *pstrDelStationMsg = &strHostIFmsg.uniHostIFmsgBody.strDelStaParam;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7420,9 +7283,8 @@ s32 host_int_del_station(WILC_WFIDrvHandle hWFIDrv, const u8 *pu8MacAddr)
                WILC_memcpy(pstrDelStationMsg->au8MacAddr, pu8MacAddr, ETH_ALEN);
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
 
        WILC_CATCH(s32Error)
        {
@@ -7449,9 +7311,8 @@ s32 host_int_del_allstation(WILC_WFIDrvHandle hWFIDrv, u8 pu8MacAddr[][ETH_ALEN]
        u8 u8AssocNumb = 0;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7479,10 +7340,9 @@ s32 host_int_del_allstation(WILC_WFIDrvHandle hWFIDrv, u8 pu8MacAddr[][ETH_ALEN]
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
 
 
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
 
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7509,9 +7369,8 @@ s32 host_int_edit_station(WILC_WFIDrvHandle hWFIDrv, tstrWILC_AddStaParam *pstrS
        tstrHostIFmsg strHostIFmsg;
        tstrWILC_AddStaParam *pstrAddStationMsg = &strHostIFmsg.uniHostIFmsgBody.strAddStaParam;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        PRINT_D(HOSTINF_DBG, "Setting editing station message queue params\n");
 
@@ -7525,15 +7384,15 @@ s32 host_int_edit_station(WILC_WFIDrvHandle hWFIDrv, tstrWILC_AddStaParam *pstrS
        WILC_memcpy(pstrAddStationMsg, pstrStaParams, sizeof(tstrWILC_AddStaParam));
        if (pstrAddStationMsg->u8NumRates > 0) {
                u8 *rates = WILC_MALLOC(pstrAddStationMsg->u8NumRates);
+
                WILC_NULLCHECK(s32Error, rates);
                WILC_memcpy(rates, pstrStaParams->pu8Rates, pstrAddStationMsg->u8NumRates);
                pstrAddStationMsg->pu8Rates = rates;
        }
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
        }
@@ -7549,11 +7408,10 @@ s32 host_int_set_power_mgmt(WILC_WFIDrvHandle hWFIDrv, bool bIsEnabled, u32 u32T
        tstrHostIFmsg strHostIFmsg;
        tstrHostIfPowerMgmtParam *pstrPowerMgmtParam = &strHostIFmsg.uniHostIFmsgBody.strPowerMgmtparam;
 
-       PRINT_INFO(HOSTINF_DBG, "\n\n>> Setting PS to %d << \n\n", bIsEnabled);
+       PRINT_INFO(HOSTINF_DBG, "\n\n>> Setting PS to %d <<\n\n", bIsEnabled);
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        PRINT_D(HOSTINF_DBG, "Setting Power management message queue params\n");
 
@@ -7569,9 +7427,8 @@ s32 host_int_set_power_mgmt(WILC_WFIDrvHandle hWFIDrv, bool bIsEnabled, u32 u32T
 
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
        }
@@ -7587,9 +7444,8 @@ s32 host_int_setup_multicast_filter(WILC_WFIDrvHandle hWFIDrv, bool bIsEnabled,
        tstrHostIFSetMulti *pstrMulticastFilterParam = &strHostIFmsg.uniHostIFmsgBody.strHostIfSetMulti;
 
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        PRINT_D(HOSTINF_DBG, "Setting Multicast Filter params\n");
 
@@ -7604,9 +7460,8 @@ s32 host_int_setup_multicast_filter(WILC_WFIDrvHandle hWFIDrv, bool bIsEnabled,
        pstrMulticastFilterParam->u32count = u32count;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
        }
@@ -7698,7 +7553,7 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                        /* HT Cap. IE */
                        else if (pu8IEs[index] == HT_CAPABILITY_IE) {
                                /* if IE found set the flag */
-                               pNewJoinBssParam->ht_capable = BTRUE;
+                               pNewJoinBssParam->ht_capable = true;
                                index += pu8IEs[index + 1] + 2; /* ID,Length bytes and IE body */
                                /* PRINT_D(HOSTINF_DBG,"HT_CAPABALE\n"); */
                                continue;
@@ -7709,12 +7564,11 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                                   ((pu8IEs[index + 6] == 0x00) || (pu8IEs[index + 6] == 0x01)) && /* OUI Sub Type */
                                   (pu8IEs[index + 7] == 0x01)) {
                                /* Presence of WMM Info/Param element indicates WMM capability */
-                               pNewJoinBssParam->wmm_cap = BTRUE;
+                               pNewJoinBssParam->wmm_cap = true;
 
                                /* Check if Bit 7 is set indicating U-APSD capability */
-                               if (pu8IEs[index + 8] & (1 << 7)) {
-                                       pNewJoinBssParam->uapsd_cap = BTRUE;
-                               }
+                               if (pu8IEs[index + 8] & (1 << 7))
+                                       pNewJoinBssParam->uapsd_cap = true;
                                index += pu8IEs[index + 1] + 2;
                                continue;
                        }
@@ -7724,6 +7578,7 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                                 (pu8IEs[index + 4] == 0x9a) && /* OUI */
                                 (pu8IEs[index + 5] == 0x09) && (pu8IEs[index + 6] == 0x0c)) { /* OUI Type     */
                                u16 u16P2P_count;
+
                                pNewJoinBssParam->tsf = ptstrNetworkInfo->u32Tsf;
                                pNewJoinBssParam->u8NoaEnbaled = 1;
                                pNewJoinBssParam->u8Index = pu8IEs[index + 9];
@@ -7735,9 +7590,9 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                                } else
                                        pNewJoinBssParam->u8OppEnable = 0;
                                /* HOSTINF_DBG */
-                               PRINT_D(GENERIC_DBG, "P2P Dump \n");
+                               PRINT_D(GENERIC_DBG, "P2P Dump\n");
                                for (i = 0; i < pu8IEs[index + 7]; i++)
-                                       PRINT_D(GENERIC_DBG, " %x \n", pu8IEs[index + 9 + i]);
+                                       PRINT_D(GENERIC_DBG, " %x\n", pu8IEs[index + 9 + i]);
 
                                pNewJoinBssParam->u8Count = pu8IEs[index + 11];
                                u16P2P_count = index + 12;
@@ -7777,7 +7632,7 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                                rsnIndex += 7; /* skipping id, length, version(2B) and first 3 bytes of gcipher */
                                pNewJoinBssParam->rsn_grp_policy = pu8IEs[rsnIndex];
                                rsnIndex++;
-                               /* PRINT_D(HOSTINF_DBG,"Group Policy: %0x \n",pNewJoinBssParam->rsn_grp_policy); */
+                               /* PRINT_D(HOSTINF_DBG,"Group Policy: %0x\n",pNewJoinBssParam->rsn_grp_policy); */
                                /* initialize policies with invalid values */
 
                                jumpOffset = pu8IEs[rsnIndex] * 4; /* total no.of bytes of pcipher field (count*4) */
@@ -7788,7 +7643,7 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                                pcipherCount = (pu8IEs[rsnIndex] > 3) ? 3 : pu8IEs[rsnIndex];
                                rsnIndex += 2; /* jump 2 bytes of pcipher count */
 
-                               /* PRINT_D(HOSTINF_DBG,"\npcipher:%d \n",pcipherCount); */
+                               /* PRINT_D(HOSTINF_DBG,"\npcipher:%d\n",pcipherCount); */
                                for (i = pcipherTotalCount, j = 0; i < pcipherCount + pcipherTotalCount && i < 3; i++, j++) {
                                        /* each count corresponds to 4 bytes, only last byte is saved */
                                        pNewJoinBssParam->rsn_pcip_policy[i] = pu8IEs[rsnIndex + ((j + 1) * 4) - 1];
@@ -7816,7 +7671,7 @@ static void *host_int_ParseJoinBssParam(tstrNetworkInfo *ptstrNetworkInfo)
                                        pNewJoinBssParam->rsn_cap[1] = pu8IEs[rsnIndex + 1];
                                        rsnIndex += 2;
                                }
-                               pNewJoinBssParam->rsn_found = 1;
+                               pNewJoinBssParam->rsn_found = true;
                                index += pu8IEs[index + 1] + 2; /* ID,Length bytes and IE body */
                                continue;
                        } else
@@ -7858,9 +7713,8 @@ static int host_int_addBASession(WILC_WFIDrvHandle hWFIDrv, char *pBSSID, char T
        tstrHostIFmsg strHostIFmsg;
        tstrHostIfBASessionInfo *pBASessionInfo = &strHostIFmsg.uniHostIFmsgBody.strHostIfBASessionInfo;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7874,9 +7728,8 @@ static int host_int_addBASession(WILC_WFIDrvHandle hWFIDrv, char *pBSSID, char T
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7893,9 +7746,8 @@ s32 host_int_delBASession(WILC_WFIDrvHandle hWFIDrv, char *pBSSID, char TID)
        tstrHostIFmsg strHostIFmsg;
        tstrHostIfBASessionInfo *pBASessionInfo = &strHostIFmsg.uniHostIFmsgBody.strHostIfBASessionInfo;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7907,9 +7759,8 @@ s32 host_int_delBASession(WILC_WFIDrvHandle hWFIDrv, char *pBSSID, char TID)
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7928,9 +7779,8 @@ s32 host_int_del_All_Rx_BASession(WILC_WFIDrvHandle hWFIDrv, char *pBSSID, char
        tstrHostIFmsg strHostIFmsg;
        tstrHostIfBASessionInfo *pBASessionInfo = &strHostIFmsg.uniHostIFmsgBody.strHostIfBASessionInfo;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7942,9 +7792,8 @@ s32 host_int_del_All_Rx_BASession(WILC_WFIDrvHandle hWFIDrv, char *pBSSID, char
        strHostIFmsg.drvHandler = hWFIDrv;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -7973,9 +7822,8 @@ s32 host_int_setup_ipaddress(WILC_WFIDrvHandle hWFIDrv, u8 *u16ipadd, u8 idx)
        /* TODO: Enable This feature on softap firmware */
        return 0;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -7987,9 +7835,8 @@ s32 host_int_setup_ipaddress(WILC_WFIDrvHandle hWFIDrv, u8 *u16ipadd, u8 idx)
        strHostIFmsg.uniHostIFmsgBody.strHostIfSetIP.idx = idx;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {
 
@@ -8014,9 +7861,8 @@ s32 host_int_get_ipaddress(WILC_WFIDrvHandle hWFIDrv, u8 *u16ipadd, u8 idx)
        tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv;
        tstrHostIFmsg strHostIFmsg;
 
-       if (pstrWFIDrv == NULL) {
+       if (pstrWFIDrv == NULL)
                WILC_ERRORREPORT(s32Error, WILC_INVALID_ARGUMENT);
-       }
 
        WILC_memset(&strHostIFmsg, 0, sizeof(tstrHostIFmsg));
 
@@ -8024,13 +7870,12 @@ s32 host_int_get_ipaddress(WILC_WFIDrvHandle hWFIDrv, u8 *u16ipadd, u8 idx)
        strHostIFmsg.u16MsgId = HOST_IF_MSG_GET_IPADDRESS;
 
        strHostIFmsg.uniHostIFmsgBody.strHostIfSetIP.au8IPAddr = u16ipadd;
-       strHostIFmsg.drvHandler=hWFIDrv;
-       strHostIFmsg.uniHostIFmsgBody.strHostIfSetIP.idx= idx;
+       strHostIFmsg.drvHandler = hWFIDrv;
+       strHostIFmsg.uniHostIFmsgBody.strHostIfSetIP.idx = idx;
 
        s32Error = WILC_MsgQueueSend(&gMsgQHostIF, &strHostIFmsg, sizeof(tstrHostIFmsg), NULL);
-       if (s32Error) {
+       if (s32Error)
                WILC_ERRORREPORT(s32Error, s32Error);
-       }
        WILC_CATCH(s32Error)
        {