staging: rtl8723bs: remove unnecessary return value from func
PATCH 1/1 staging: rtl8723bs: remove unnecessary return value from func
Function init_hw_mlme_ext() always returns '_SUCCESS', regardless of the result of it's work. Remove this unnecessary return and change function type to 'void' to simplify the code. Additionally, fix the line length exceeding 100 columns.
Signed-off-by Nikolay Kulikov <[email protected]>
--- drivers/staging/rtl8723bs/core/rtw_mlme_ext.c | 8 ++++---- drivers/staging/rtl8723bs/include/rtw_mlme_ext.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/staging/rtl8723bs/core/rtw_mlme_ext.c +4 -4
@@ -184,12 +184,12 @@ int rtw_ch_set_search_ch(struct rt_channel_info *ch_set, const u32 ch)/* Following are the initialization functions for WiFi MLME */ -int init_hw_mlme_ext (struct adapter *padapter) +void init_hw_mlme_ext (struct adapter *padapter) { -struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; +struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; -set_channel_bwmode (padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode); -return _SUCCESS; +set_channel_bwmode (padapter, pmlmeext->cur_channel, + pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode); }void init_mlme_default_rate_set (struct adapter *padapter)
drivers/staging/rtl8723bs/include/rtw_mlme_ext.h +1 -1
@@ -424,7 +424,7 @@ struct mlme_ext_priv {void init_mlme_default_rate_set (struct adapter *padapter);void init_mlme_ext_priv (struct adapter *padapter); -int init_hw_mlme_ext (struct adapter *padapter); +void init_hw_mlme_ext (struct adapter *padapter);void free_mlme_ext_priv (struct mlme_ext_priv *pmlmeext);extern struct xmit_frame *alloc_mgtxmitframe (struct xmit_priv *pxmitpriv);
Signature · 1 line
2.53.0
Quoted 7 lines · Nikolay Kulikov
Function
init_hw_mlme_ext()always returns '_SUCCESS', regardless of the result of it's work. Remove this unnecessary return and change function type to 'void' to simplify the code. Additionally, fix the line length exceeding 100 columns.Signed-off-by Nikolay Kulikov <[email protected]>---
LGTM.
Reviewed-by Ethan Tidmore <[email protected]>
Thanks,
ET