Commit 5a66bf20 authored by Abdul Hussain's avatar Abdul Hussain Committed by Greg Kroah-Hartman

Staging: wilc1000: Boolean tests don't need comparisons

This patch removes unwanted true and false from boolean tests.
Signed-off-by: default avatarAbdul Hussain <habdul@visteon.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f717c0eb
...@@ -1716,7 +1716,7 @@ s32 ParseResponse(u8 *resp, tstrWID *pstrWIDcfgResult) ...@@ -1716,7 +1716,7 @@ s32 ParseResponse(u8 *resp, tstrWID *pstrWIDcfgResult)
idx++; idx++;
} }
idx += 3; idx += 3;
if ((u16WIDid == g_wid_num) && (num_wid_processed == false)) { if ((u16WIDid == g_wid_num) && (!num_wid_processed)) {
num_wid_processed = true; num_wid_processed = true;
if (-2 == further_process_response(&resp[idx], u16WIDid, cfg_len, true, 0, &pstrWIDcfgResult[ResCnt])) { if (-2 == further_process_response(&resp[idx], u16WIDid, cfg_len, true, 0, &pstrWIDcfgResult[ResCnt])) {
...@@ -1922,7 +1922,7 @@ s32 ConfigWaitResponse(char *pcRespBuffer, s32 s32MaxRespBuffLen, s32 *ps32Bytes ...@@ -1922,7 +1922,7 @@ s32 ConfigWaitResponse(char *pcRespBuffer, s32 s32MaxRespBuffLen, s32 *ps32Bytes
* gstrConfigPktInfo.bRespRequired = bRespRequired;*/ * gstrConfigPktInfo.bRespRequired = bRespRequired;*/
if (gstrConfigPktInfo.bRespRequired == true) { if (gstrConfigPktInfo.bRespRequired) {
down(&SemHandlePktResp); down(&SemHandlePktResp);
*ps32BytesRead = gstrConfigPktInfo.s32BytesRead; *ps32BytesRead = gstrConfigPktInfo.s32BytesRead;
...@@ -1983,7 +1983,7 @@ s32 SendConfigPkt(u8 u8Mode, tstrWID *pstrWIDs, ...@@ -1983,7 +1983,7 @@ s32 SendConfigPkt(u8 u8Mode, tstrWID *pstrWIDs,
ConfigWaitResponse(gps8ConfigPacket, MAX_PACKET_BUFF_SIZE, &s32RcvdRespLen, bRespRequired); ConfigWaitResponse(gps8ConfigPacket, MAX_PACKET_BUFF_SIZE, &s32RcvdRespLen, bRespRequired);
if (bRespRequired == true) { if (bRespRequired) {
/* If the operating Mode is GET, then we expect a response frame from */ /* If the operating Mode is GET, then we expect a response frame from */
/* the driver. Hence start listening to the port for response */ /* the driver. Hence start listening to the port for response */
if (g_oper_mode == GET_CFG) { if (g_oper_mode == GET_CFG) {
...@@ -2020,7 +2020,7 @@ s32 ConfigProvideResponse(char *pcRespBuffer, s32 s32RespLen) ...@@ -2020,7 +2020,7 @@ s32 ConfigProvideResponse(char *pcRespBuffer, s32 s32RespLen)
{ {
s32 s32Error = WILC_SUCCESS; s32 s32Error = WILC_SUCCESS;
if (gstrConfigPktInfo.bRespRequired == true) { if (gstrConfigPktInfo.bRespRequired) {
if (s32RespLen <= gstrConfigPktInfo.s32MaxRespBuffLen) { if (s32RespLen <= gstrConfigPktInfo.s32MaxRespBuffLen) {
WILC_memcpy(gstrConfigPktInfo.pcRespBuffer, pcRespBuffer, s32RespLen); WILC_memcpy(gstrConfigPktInfo.pcRespBuffer, pcRespBuffer, s32RespLen);
gstrConfigPktInfo.s32BytesRead = s32RespLen; gstrConfigPktInfo.s32BytesRead = s32RespLen;
......
...@@ -452,7 +452,7 @@ void WILC_mgm_HOSTAPD_ACK(void *priv, bool bStatus) ...@@ -452,7 +452,7 @@ void WILC_mgm_HOSTAPD_ACK(void *priv, bool bStatus)
cb_hdr->rate = 5; /* txrate->bitrate / 5; */ cb_hdr->rate = 5; /* txrate->bitrate / 5; */
if (true == bStatus) { if (bStatus) {
/* success */ /* success */
cb_hdr->tx_flags = IEEE80211_RADIOTAP_F_TX_RTS; cb_hdr->tx_flags = IEEE80211_RADIOTAP_F_TX_RTS;
} else { } else {
......
...@@ -309,7 +309,7 @@ static int dev_state_ev_handler(struct notifier_block *this, unsigned long event ...@@ -309,7 +309,7 @@ static int dev_state_ev_handler(struct notifier_block *this, unsigned long event
if (bEnablePS == true) if (bEnablePS)
host_int_set_power_mgmt((WILC_WFIDrvHandle)pstrWFIDrv, 1, 0); host_int_set_power_mgmt((WILC_WFIDrvHandle)pstrWFIDrv, 1, 0);
PRINT_D(GENERIC_DBG, "[%s] Up IP\n", dev_iface->ifa_label); PRINT_D(GENERIC_DBG, "[%s] Up IP\n", dev_iface->ifa_label);
......
...@@ -624,7 +624,7 @@ static void CfgConnectResult(tenuConnDisconnEvent enuConnDisconnEvent, ...@@ -624,7 +624,7 @@ static void CfgConnectResult(tenuConnDisconnEvent enuConnDisconnEvent,
} }
} }
if (bNeedScanRefresh == true) { if (bNeedScanRefresh) {
/*BugID_5418*/ /*BugID_5418*/
/*Also, refrsh DIRECT- results if */ /*Also, refrsh DIRECT- results if */
refresh_scan(priv, 1, true); refresh_scan(priv, 1, true);
...@@ -2817,7 +2817,7 @@ int WILC_WFI_set_power_mgmt(struct wiphy *wiphy, struct net_device *dev, ...@@ -2817,7 +2817,7 @@ int WILC_WFI_set_power_mgmt(struct wiphy *wiphy, struct net_device *dev,
return -EIO; return -EIO;
} }
if (bEnablePS == true) if (bEnablePS)
host_int_set_power_mgmt(priv->hWILCWFIDrv, enabled, timeout); host_int_set_power_mgmt(priv->hWILCWFIDrv, enabled, timeout);
......
...@@ -559,7 +559,7 @@ static int wilc_wlan_txq_add_net_pkt(void *priv, uint8_t *buffer, uint32_t buffe ...@@ -559,7 +559,7 @@ static int wilc_wlan_txq_add_net_pkt(void *priv, uint8_t *buffer, uint32_t buffe
#ifdef TCP_ACK_FILTER #ifdef TCP_ACK_FILTER
tqe->tcp_PendingAck_index = NOT_TCP_ACK; tqe->tcp_PendingAck_index = NOT_TCP_ACK;
#ifdef TCP_ENHANCEMENTS #ifdef TCP_ENHANCEMENTS
if (is_TCP_ACK_Filter_Enabled() == true) if (is_TCP_ACK_Filter_Enabled())
#endif #endif
tcp_process(tqe); tcp_process(tqe);
#endif #endif
...@@ -2337,7 +2337,7 @@ u16 Set_machw_change_vir_if(bool bValue) ...@@ -2337,7 +2337,7 @@ u16 Set_machw_change_vir_if(bool bValue)
PRINT_ER("Error while Reading reg WILC_CHANGING_VIR_IF\n"); PRINT_ER("Error while Reading reg WILC_CHANGING_VIR_IF\n");
} }
if (bValue == true) { if (bValue) {
reg |= (BIT31); reg |= (BIT31);
} else { } else {
reg &= ~(BIT31); reg &= ~(BIT31);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment