[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1648457022-4076-1-git-send-email-baihaowen@meizu.com>
Date: Mon, 28 Mar 2022 16:43:42 +0800
From: Haowen Bai <baihaowen@...zu.com>
To: <Larry.Finger@...inger.net>, <phil@...lpotter.co.uk>,
<gregkh@...uxfoundation.org>, <straube.linux@...il.com>,
<martin@...ser.cx>
CC: <linux-staging@...ts.linux.dev>, <linux-kernel@...r.kernel.org>,
"Haowen Bai" <baihaowen@...zu.com>
Subject: [PATCH V2] staging: r8188eu: Directly return _FAIL instead of using local ret variable
fixes coccinelle warning:
./drivers/staging/r8188eu/core/rtw_mlme_ext.c:1518:14-17: Unneeded variable: "ret".
Return "_FAIL" on line 1549
Signed-off-by: Haowen Bai <baihaowen@...zu.com>
---
V1->V2: split into two patches.
drivers/staging/r8188eu/core/rtw_mlme_ext.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/r8188eu/core/rtw_mlme_ext.c b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
index 10d5f12..931e6f2 100644
--- a/drivers/staging/r8188eu/core/rtw_mlme_ext.c
+++ b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
@@ -1515,7 +1515,6 @@ unsigned int OnAtim(struct adapter *padapter, struct recv_frame *precv_frame)
unsigned int on_action_spct(struct adapter *padapter, struct recv_frame *precv_frame)
{
- unsigned int ret = _FAIL;
struct sta_info *psta = NULL;
struct sta_priv *pstapriv = &padapter->stapriv;
u8 *pframe = precv_frame->rx_data;
@@ -1546,7 +1545,7 @@ unsigned int on_action_spct(struct adapter *padapter, struct recv_frame *precv_f
}
exit:
- return ret;
+ return _FAIL;
}
unsigned int OnAction_qos(struct adapter *padapter, struct recv_frame *precv_frame)
--
2.7.4
Powered by blists - more mailing lists