提交 1663863a 编写于 作者: S Sevinj Aghayeva 提交者: Greg Kroah-Hartman

staging: rtl8723bs: remove redundant else branches

Adhere to Linux kernel coding style.

Reported by checkpatch:

WARNING: else is not generally useful after a break or return
Signed-off-by: NSevinj Aghayeva <sevinj.aghayeva@gmail.com>
Link: https://lore.kernel.org/r/fcb50e467d5ac81becf222379bcc21136966b86b.1649128267.git.sevinj.aghayeva@gmail.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 3c22d177
...@@ -908,10 +908,9 @@ unsigned int OnAuthClient(struct adapter *padapter, union recv_frame *precv_fram ...@@ -908,10 +908,9 @@ unsigned int OnAuthClient(struct adapter *padapter, union recv_frame *precv_fram
set_link_timer(pmlmeext, REAUTH_TO); set_link_timer(pmlmeext, REAUTH_TO);
return _SUCCESS; return _SUCCESS;
} else { }
/* open system */ /* open system */
go2asoc = 1; go2asoc = 1;
}
} else if (seq == 4) { } else if (seq == 4) {
if (pmlmeinfo->auth_algo == dot11AuthAlgrthm_Shared) if (pmlmeinfo->auth_algo == dot11AuthAlgrthm_Shared)
go2asoc = 1; go2asoc = 1;
...@@ -1468,6 +1467,7 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame) ...@@ -1468,6 +1467,7 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame)
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info); struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
u8 *pframe = precv_frame->u.hdr.rx_data; u8 *pframe = precv_frame->u.hdr.rx_data;
int ignore_received_deauth = 0;
/* check A3 */ /* check A3 */
if (memcmp(GetAddr3Ptr(pframe), get_my_bssid(&pmlmeinfo->network), ETH_ALEN)) if (memcmp(GetAddr3Ptr(pframe), get_my_bssid(&pmlmeinfo->network), ETH_ALEN))
...@@ -1503,8 +1503,7 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame) ...@@ -1503,8 +1503,7 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame)
return _SUCCESS; return _SUCCESS;
} else { }
int ignore_received_deauth = 0;
/* Commented by Albert 20130604 */ /* Commented by Albert 20130604 */
/* Before sending the auth frame to start the STA/GC mode connection with AP/GO, */ /* Before sending the auth frame to start the STA/GC mode connection with AP/GO, */
...@@ -1528,10 +1527,9 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame) ...@@ -1528,10 +1527,9 @@ unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame)
if (ignore_received_deauth == 0) if (ignore_received_deauth == 0)
receive_disconnect(padapter, GetAddr3Ptr(pframe), reason); receive_disconnect(padapter, GetAddr3Ptr(pframe), reason);
}
pmlmepriv->LinkDetectInfo.bBusyTraffic = false; pmlmepriv->LinkDetectInfo.bBusyTraffic = false;
return _SUCCESS; return _SUCCESS;
} }
unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame) unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame)
...@@ -1575,13 +1573,13 @@ unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame) ...@@ -1575,13 +1573,13 @@ unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame)
} }
return _SUCCESS; return _SUCCESS;
} else { }
netdev_dbg(padapter->pnetdev, netdev_dbg(padapter->pnetdev,
"sta recv disassoc reason code(%d) sta:%pM\n", "sta recv disassoc reason code(%d) sta:%pM\n",
reason, GetAddr3Ptr(pframe)); reason, GetAddr3Ptr(pframe));
receive_disconnect(padapter, GetAddr3Ptr(pframe), reason); receive_disconnect(padapter, GetAddr3Ptr(pframe), reason);
}
pmlmepriv->LinkDetectInfo.bBusyTraffic = false; pmlmepriv->LinkDetectInfo.bBusyTraffic = false;
return _SUCCESS; return _SUCCESS;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册