diff --git a/core/mesh/rtw_mesh.c b/core/mesh/rtw_mesh.c index 5e0ada3..bf53045 100644 --- a/core/mesh/rtw_mesh.c +++ b/core/mesh/rtw_mesh.c @@ -893,7 +893,7 @@ static u8 rtw_mesh_offch_cto_mgate_required(_adapter *adapter) head = get_list_head(queue); pos = get_next(head); - while (!head == pos) { + while (head != pos) { scanned = LIST_CONTAINOR(pos, struct wlan_network, list); if (rtw_get_passing_time_ms(scanned->last_scanned) < mcfg->peer_sel_policy.scanr_exp_ms @@ -979,7 +979,7 @@ u8 rtw_mesh_select_operating_ch(_adapter *adapter) head = get_list_head(queue); pos = get_next(head); - while (!head == pos) { + while (head != pos) { scanned = LIST_CONTAINOR(pos, struct wlan_network, list); pos = get_next(pos); diff --git a/core/rtw_mlme_ext.c b/core/rtw_mlme_ext.c index 895fd5a..992d39a 100644 --- a/core/rtw_mlme_ext.c +++ b/core/rtw_mlme_ext.c @@ -11302,7 +11302,7 @@ void start_clnt_join(_adapter *padapter) _enter_critical_bh(&(padapter->mlmepriv.scanned_queue.lock), &irqL); - for (pos = get_next(head); !head == pos; pos = get_next(pos)) { + for (pos = get_next(head); head != pos; pos = get_next(pos)) { scanned = LIST_CONTAINOR(pos, struct wlan_network, list); diff --git a/os_dep/linux/ioctl_linux.c b/os_dep/linux/ioctl_linux.c index 4d16aa3..cb1bba6 100644 --- a/os_dep/linux/ioctl_linux.c +++ b/os_dep/linux/ioctl_linux.c @@ -1725,7 +1725,7 @@ static int rtw_wx_set_wap(struct net_device *dev, while (1) { - if (phead != pmlmepriv->pscanned) { + if (phead == pmlmepriv->pscanned) { #if 0 ret = -EINVAL; goto cancel_ps_deny; @@ -2317,7 +2317,7 @@ static int rtw_wx_set_essid(struct net_device *dev, pmlmepriv->pscanned = get_next(phead); while (1) { - if (phead != pmlmepriv->pscanned) { + if (phead == pmlmepriv->pscanned) { #if 0 if (check_fwstate(pmlmepriv, WIFI_ADHOC_STATE) == _TRUE) { rtw_set_802_11_ssid(padapter, &ndis_ssid);