staging: rtl8723bs: Remove set but not used variable 'reason_code'
PATCH 1/1 staging: rtl8723bs: Remove set but not used variable 'reason_code'
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/staging/rtl8723bs/core/rtw_mlme_ext.c: In function 'OnAction_back':drivers/staging/rtl8723bs/core/rtw_mlme_ext.c:1729:30: warning:
variable ‘reason_code’ set but not used [-Wunused-but-set-variable]
It never used since introduction.
--- drivers/staging/rtl8723bs/core/rtw_mlme_ext.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/staging/rtl8723bs/core/rtw_mlme_ext.c +1 -4
@@ -1721,7 +1721,7 @@ unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_frastruct recv_reorder_ctrl *preorder_ctrl;unsigned char *frame_body;unsigned char category, action; -unsigned short tid, status, reason_code =0 ; +unsigned short tid, status;struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);u8 *pframe = precv_frame->u.hdr.rx_data;
@@ -1790,9 +1790,6 @@ unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_fra ~BIT ((frame_body[3 ] >>4 ) &0xf ); psta->htpriv.candidate_tid_bitmap &= ~BIT ((frame_body[3 ] >>4 ) &0xf ); - -/* reason_code = frame_body[4] | (frame_body[5] << 8); */ - reason_code =get_unaligned_le16 (&frame_body[4 ]); }else if ((frame_body[3 ] &BIT (3 )) ==BIT (3 )) { tid = (frame_body[3 ] >>4 ) &0x0F ;
Signature · 1 line
2.25.4
Greg KH
maintainerQuoted 39 lines · Baokun Li
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/staging/rtl8723bs/core/rtw_mlme_ext.c: In function 'OnAction_back':drivers/staging/rtl8723bs/core/rtw_mlme_ext.c:1729:30: warning:
variable ‘reason_code’ set but not used [-Wunused-but-set-variable]It never used since introduction.
Signed-off-by Baokun Li <[email protected]>--- drivers/staging/rtl8723bs/core/rtw_mlme_ext.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)drivers/staging/rtl8723bs/core/rtw_mlme_ext.c +1
-4@@ -1721,7 +1721,7 @@ unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_frastruct recv_reorder_ctrl *preorder_ctrl;unsigned char *frame_body;unsigned char category, action; -unsigned short tid, status, reason_code =0 ; +unsigned short tid, status;struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);u8 *pframe = precv_frame->u.hdr.rx_data;@@ -1790,9 +1790,6 @@ unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_fra ~BIT ((frame_body[3 ] >>4 ) &0xf ); psta->htpriv.candidate_tid_bitmap &= ~BIT ((frame_body[3 ] >>4 ) &0xf ); - -/* reason_code = frame_body[4] | (frame_body[5] << 8); */ - reason_code =get_unaligned_le16 (&frame_body[4 ]); }else if ((frame_body[3 ] &BIT (3 )) ==BIT (3 )) { tid = (frame_body[3 ] >>4 ) &0x0F ;Signature · 1 line
2.25.4
Does not apply to my tree. Are you _sure_ you are using the latest version of linux-next?
thanks,
greg k-h