* [PATCH 0/5] staging: r8188eu: another set of small fixes
@ 2022-05-15 15:53 Martin Kaiser
2022-05-15 15:53 ` [PATCH 1/5] staging: r8188eu: use ieee80211 helper to check for beacon Martin Kaiser
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Martin Kaiser @ 2022-05-15 15:53 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Larry Finger, Phillip Potter, Michael Straube, linux-staging,
linux-kernel, Martin Kaiser
A couple of simple fixes in several places.
Martin Kaiser (5):
staging: r8188eu: use ieee80211 helper to check for beacon
staging: r8188eu: remove obsolete comments
staging: r8188eu: simplify error handling in recv_func_prehandle
staging: r8188eu: last_rx_mgnt_pkts is set but not used
staging: r8188eu: assoc_rsp and assoc_rsp_len are not used
drivers/staging/r8188eu/core/rtw_mlme.c | 1 -
drivers/staging/r8188eu/core/rtw_mlme_ext.c | 6 -----
drivers/staging/r8188eu/core/rtw_recv.c | 5 +----
drivers/staging/r8188eu/hal/HalPwrSeqCmd.c | 22 -------------------
drivers/staging/r8188eu/hal/rtl8188e_rxdesc.c | 4 +---
drivers/staging/r8188eu/include/rtw_mlme.h | 2 --
drivers/staging/r8188eu/include/sta_info.h | 2 --
7 files changed, 2 insertions(+), 40 deletions(-)
--
2.30.2
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 1/5] staging: r8188eu: use ieee80211 helper to check for beacon
2022-05-15 15:53 [PATCH 0/5] staging: r8188eu: another set of small fixes Martin Kaiser
@ 2022-05-15 15:53 ` Martin Kaiser
2022-05-15 15:53 ` [PATCH 2/5] staging: r8188eu: remove obsolete comments Martin Kaiser
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Martin Kaiser @ 2022-05-15 15:53 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Larry Finger, Phillip Potter, Michael Straube, linux-staging,
linux-kernel, Martin Kaiser
Use the ieee80211_is_beacon helper to check if the incoming frame is a
beacon frame.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/staging/r8188eu/hal/rtl8188e_rxdesc.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/staging/r8188eu/hal/rtl8188e_rxdesc.c b/drivers/staging/r8188eu/hal/rtl8188e_rxdesc.c
index 7e50a42b6f75..dff0cba751df 100644
--- a/drivers/staging/r8188eu/hal/rtl8188e_rxdesc.c
+++ b/drivers/staging/r8188eu/hal/rtl8188e_rxdesc.c
@@ -128,9 +128,7 @@ void update_recvframe_phyinfo_88e(struct recv_frame *precvframe, struct phy_stat
(!memcmp(get_da(wlanhdr),
myid(&padapter->eeprompriv), ETH_ALEN));
- pkt_info.bPacketBeacon = pkt_info.bPacketMatchBSSID &&
- (GetFrameSubType(wlanhdr) == WIFI_BEACON);
-
+ pkt_info.bPacketBeacon = pkt_info.bPacketMatchBSSID && ieee80211_is_beacon(fc);
if (pkt_info.bPacketBeacon) {
if (check_fwstate(&padapter->mlmepriv, WIFI_STATION_STATE))
sa = padapter->mlmepriv.cur_network.network.MacAddress;
--
2.30.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/5] staging: r8188eu: remove obsolete comments
2022-05-15 15:53 [PATCH 0/5] staging: r8188eu: another set of small fixes Martin Kaiser
2022-05-15 15:53 ` [PATCH 1/5] staging: r8188eu: use ieee80211 helper to check for beacon Martin Kaiser
@ 2022-05-15 15:53 ` Martin Kaiser
2022-05-15 15:53 ` [PATCH 3/5] staging: r8188eu: simplify error handling in recv_func_prehandle Martin Kaiser
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Martin Kaiser @ 2022-05-15 15:53 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Larry Finger, Phillip Potter, Michael Straube, linux-staging,
linux-kernel, Martin Kaiser
Remove some comments in HalPwrSeqCmd.c that contain no useful information.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/staging/r8188eu/hal/HalPwrSeqCmd.c | 22 ----------------------
1 file changed, 22 deletions(-)
diff --git a/drivers/staging/r8188eu/hal/HalPwrSeqCmd.c b/drivers/staging/r8188eu/hal/HalPwrSeqCmd.c
index 5b91aec6a7e3..150ea380c39e 100644
--- a/drivers/staging/r8188eu/hal/HalPwrSeqCmd.c
+++ b/drivers/staging/r8188eu/hal/HalPwrSeqCmd.c
@@ -1,30 +1,8 @@
// SPDX-License-Identifier: GPL-2.0
/* Copyright(c) 2007 - 2011 Realtek Corporation. */
-/*++
-
-Module Name:
- HalPwrSeqCmd.c
-
-Abstract:
- Implement HW Power sequence configuration CMD handling routine for Realtek devices.
-
-Major Change History:
- When Who What
- ---------- --------------- -------------------------------
- 2011-10-26 Lucas Modify to be compatible with SD4-CE driver.
- 2011-07-07 Roger Create.
-
---*/
-
#include "../include/HalPwrSeqCmd.h"
-/* Description: */
-/* This routine deals with the Power Configuration CMDs parsing
- * for RTL8723/RTL8188E Series IC.
- * Assumption:
- * We should follow specific format which was released from HW SD.
- */
u8 HalPwrSeqCmdParsing(struct adapter *padapter, struct wl_pwr_cfg pwrseqcmd[])
{
struct wl_pwr_cfg pwrcfgcmd = {0};
--
2.30.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 3/5] staging: r8188eu: simplify error handling in recv_func_prehandle
2022-05-15 15:53 [PATCH 0/5] staging: r8188eu: another set of small fixes Martin Kaiser
2022-05-15 15:53 ` [PATCH 1/5] staging: r8188eu: use ieee80211 helper to check for beacon Martin Kaiser
2022-05-15 15:53 ` [PATCH 2/5] staging: r8188eu: remove obsolete comments Martin Kaiser
@ 2022-05-15 15:53 ` Martin Kaiser
2022-05-15 15:54 ` [PATCH 4/5] staging: r8188eu: last_rx_mgnt_pkts is set but not used Martin Kaiser
2022-05-15 15:54 ` [PATCH 5/5] staging: r8188eu: assoc_rsp and assoc_rsp_len are " Martin Kaiser
4 siblings, 0 replies; 6+ messages in thread
From: Martin Kaiser @ 2022-05-15 15:53 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Larry Finger, Phillip Potter, Michael Straube, linux-staging,
linux-kernel, Martin Kaiser
Simplify the error handling in recv_func_prehandle. There's no need to
goto exit, this would be the next statement anyway.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/staging/r8188eu/core/rtw_recv.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/staging/r8188eu/core/rtw_recv.c b/drivers/staging/r8188eu/core/rtw_recv.c
index 4060c0457613..df518439aea2 100644
--- a/drivers/staging/r8188eu/core/rtw_recv.c
+++ b/drivers/staging/r8188eu/core/rtw_recv.c
@@ -1673,12 +1673,9 @@ static int recv_func_prehandle(struct adapter *padapter, struct recv_frame *rfra
/* check the frame crtl field and decache */
ret = validate_recv_frame(padapter, rframe);
- if (ret != _SUCCESS) {
+ if (ret != _SUCCESS)
rtw_free_recvframe(rframe, pfree_recv_queue);/* free this recv_frame */
- goto exit;
- }
-exit:
return ret;
}
--
2.30.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 4/5] staging: r8188eu: last_rx_mgnt_pkts is set but not used
2022-05-15 15:53 [PATCH 0/5] staging: r8188eu: another set of small fixes Martin Kaiser
` (2 preceding siblings ...)
2022-05-15 15:53 ` [PATCH 3/5] staging: r8188eu: simplify error handling in recv_func_prehandle Martin Kaiser
@ 2022-05-15 15:54 ` Martin Kaiser
2022-05-15 15:54 ` [PATCH 5/5] staging: r8188eu: assoc_rsp and assoc_rsp_len are " Martin Kaiser
4 siblings, 0 replies; 6+ messages in thread
From: Martin Kaiser @ 2022-05-15 15:54 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Larry Finger, Phillip Potter, Michael Straube, linux-staging,
linux-kernel, Martin Kaiser
last_rx_mgnt_pkts in struct stainfo_stats is set but not used.
Remove it.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/staging/r8188eu/include/sta_info.h | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/r8188eu/include/sta_info.h b/drivers/staging/r8188eu/include/sta_info.h
index b7e6b1f319a2..4112c837bcef 100644
--- a/drivers/staging/r8188eu/include/sta_info.h
+++ b/drivers/staging/r8188eu/include/sta_info.h
@@ -48,7 +48,6 @@ struct stainfo_stats {
u64 rx_ctrl_pkts;
u64 rx_data_pkts;
- u64 last_rx_mgnt_pkts;
u64 last_rx_beacon_pkts;
u64 last_rx_probereq_pkts;
u64 last_rx_probersp_pkts;
@@ -230,7 +229,6 @@ struct sta_info {
#define sta_update_last_rx_pkts(sta) \
do { \
- sta->sta_stats.last_rx_mgnt_pkts = sta->sta_stats.rx_mgnt_pkts; \
sta->sta_stats.last_rx_beacon_pkts = sta->sta_stats.rx_beacon_pkts; \
sta->sta_stats.last_rx_probereq_pkts = sta->sta_stats.rx_probereq_pkts; \
sta->sta_stats.last_rx_probersp_pkts = sta->sta_stats.rx_probersp_pkts; \
--
2.30.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 5/5] staging: r8188eu: assoc_rsp and assoc_rsp_len are not used
2022-05-15 15:53 [PATCH 0/5] staging: r8188eu: another set of small fixes Martin Kaiser
` (3 preceding siblings ...)
2022-05-15 15:54 ` [PATCH 4/5] staging: r8188eu: last_rx_mgnt_pkts is set but not used Martin Kaiser
@ 2022-05-15 15:54 ` Martin Kaiser
4 siblings, 0 replies; 6+ messages in thread
From: Martin Kaiser @ 2022-05-15 15:54 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Larry Finger, Phillip Potter, Michael Straube, linux-staging,
linux-kernel, Martin Kaiser
The assoc_rsp buffer in struct mlme_priv is not used. There's no need to
store an incoming association response after receiving an processing it.
Remove the buffer pointer and its length from struct mlme_priv.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/staging/r8188eu/core/rtw_mlme.c | 1 -
drivers/staging/r8188eu/core/rtw_mlme_ext.c | 6 ------
drivers/staging/r8188eu/include/rtw_mlme.h | 2 --
3 files changed, 9 deletions(-)
diff --git a/drivers/staging/r8188eu/core/rtw_mlme.c b/drivers/staging/r8188eu/core/rtw_mlme.c
index c44e636d2c05..5a815642c3f6 100644
--- a/drivers/staging/r8188eu/core/rtw_mlme.c
+++ b/drivers/staging/r8188eu/core/rtw_mlme.c
@@ -40,7 +40,6 @@ static void rtw_free_mlme_ie_data(u8 **ppie, u32 *plen)
void rtw_free_mlme_priv_ie_data(struct mlme_priv *pmlmepriv)
{
kfree(pmlmepriv->assoc_req);
- kfree(pmlmepriv->assoc_rsp);
rtw_free_mlme_ie_data(&pmlmepriv->wps_beacon_ie, &pmlmepriv->wps_beacon_ie_len);
rtw_free_mlme_ie_data(&pmlmepriv->wps_probe_req_ie, &pmlmepriv->wps_probe_req_ie_len);
rtw_free_mlme_ie_data(&pmlmepriv->wps_probe_resp_ie, &pmlmepriv->wps_probe_resp_ie_len);
diff --git a/drivers/staging/r8188eu/core/rtw_mlme_ext.c b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
index 65330baa5a73..faf23fc950c5 100644
--- a/drivers/staging/r8188eu/core/rtw_mlme_ext.c
+++ b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
@@ -1272,7 +1272,6 @@ unsigned int OnAssocRsp(struct adapter *padapter, struct recv_frame *precv_frame
int res;
unsigned short status;
struct ndis_802_11_var_ie *pIE;
- struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &pmlmeext->mlmext_info;
/* struct wlan_bssid_ex *cur_network = &(pmlmeinfo->network); */
@@ -1343,11 +1342,6 @@ unsigned int OnAssocRsp(struct adapter *padapter, struct recv_frame *precv_frame
UpdateBrateTbl(padapter, pmlmeinfo->network.SupportedRates);
report_assoc_result:
- if (res > 0)
- rtw_buf_update(&pmlmepriv->assoc_rsp, &pmlmepriv->assoc_rsp_len, pframe, pkt_len);
- else
- kfree(pmlmepriv->assoc_rsp);
-
report_join_res(padapter, res);
return _SUCCESS;
diff --git a/drivers/staging/r8188eu/include/rtw_mlme.h b/drivers/staging/r8188eu/include/rtw_mlme.h
index 95c23bf1139d..d81668498e46 100644
--- a/drivers/staging/r8188eu/include/rtw_mlme.h
+++ b/drivers/staging/r8188eu/include/rtw_mlme.h
@@ -363,8 +363,6 @@ struct mlme_priv {
u8 *assoc_req;
u32 assoc_req_len;
- u8 *assoc_rsp;
- u32 assoc_rsp_len;
/* Number of associated Non-ERP stations (i.e., stations using 802.11b
* in 802.11g BSS) */
--
2.30.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2022-05-15 15:54 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-15 15:53 [PATCH 0/5] staging: r8188eu: another set of small fixes Martin Kaiser
2022-05-15 15:53 ` [PATCH 1/5] staging: r8188eu: use ieee80211 helper to check for beacon Martin Kaiser
2022-05-15 15:53 ` [PATCH 2/5] staging: r8188eu: remove obsolete comments Martin Kaiser
2022-05-15 15:53 ` [PATCH 3/5] staging: r8188eu: simplify error handling in recv_func_prehandle Martin Kaiser
2022-05-15 15:54 ` [PATCH 4/5] staging: r8188eu: last_rx_mgnt_pkts is set but not used Martin Kaiser
2022-05-15 15:54 ` [PATCH 5/5] staging: r8188eu: assoc_rsp and assoc_rsp_len are " Martin Kaiser
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).