[PATCH 23/61] staging: rtl8723bs: remove issue_probereq wrapper and rename helper
From: Arsenii Pashchenko
Date: Wed Jul 15 2026 - 08:54:06 EST
Remove the redundant issue_probereq() wrapper function from
rtw_mlme_ext.c, which did nothing but pass fixed default arguments
to _issue_probereq().
Simplify the code by renaming the internal _issue_probereq() helper
to issue_probereq() and exposing its full signature. Update its only
call sites across the driver to pass the required explicit arguments
(0, 1, false) directly.
This eliminates the useless leading underscore naming convention,
reduces unnecessary abstraction layers, and cleans up the MLME
extension interface.
Signed-off-by: Arsenii Pashchenko <ulijg308@xxxxxxxxx>
---
drivers/staging/rtl8723bs/core/rtw_mlme_ext.c | 24 ++++++++++---------
.../staging/rtl8723bs/include/rtw_mlme_ext.h | 3 ++-
2 files changed, 15 insertions(+), 12 deletions(-)
diff --git a/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c b/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c
index 54690c2fc..0c5770f09 100644
--- a/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c
+++ b/drivers/staging/rtl8723bs/core/rtw_mlme_ext.c
@@ -2357,7 +2357,7 @@ void issue_probersp(struct adapter *padapter, unsigned char *da, u8 is_valid_p2p
dump_mgntframe(padapter, pmgntframe);
}
-static int _issue_probereq(struct adapter *padapter,
+int issue_probereq(struct adapter *padapter,
struct ndis_802_11_ssid *pssid,
u8 *da, u8 ch, bool append_wps, bool wait_ack)
{
@@ -2450,10 +2450,6 @@ static int _issue_probereq(struct adapter *padapter,
return ret;
}
-inline void issue_probereq(struct adapter *padapter, struct ndis_802_11_ssid *pssid, u8 *da)
-{
- _issue_probereq(padapter, pssid, da, 0, 1, false);
-}
int issue_probereq_ex(struct adapter *padapter, struct ndis_802_11_ssid *pssid, u8 *da, u8 ch, bool append_wps,
int try_cnt, int wait_ms)
@@ -2462,7 +2458,7 @@ int issue_probereq_ex(struct adapter *padapter, struct ndis_802_11_ssid *pssid,
int i = 0;
do {
- ret = _issue_probereq(padapter, pssid, da, ch, append_wps,
+ ret = issue_probereq(padapter, pssid, da, ch, append_wps,
wait_ms > 0);
i++;
@@ -3703,20 +3699,26 @@ void site_survey(struct adapter *padapter)
/* IOT issue, When wifi_spec is not set, send one probe req without WPS IE. */
if (padapter->registrypriv.wifi_spec)
- issue_probereq(padapter, &(pmlmeext->sitesurvey_res.ssid[i]), NULL);
+ issue_probereq(padapter,
+ &pmlmeext->sitesurvey_res.ssid[i],
+ NULL, 0, 1, false);
else
- issue_probereq_ex(padapter, &(pmlmeext->sitesurvey_res.ssid[i]), NULL, 0, 0, 0, 0);
+ issue_probereq_ex(padapter,
+ &pmlmeext->sitesurvey_res.ssid[i],
+ NULL, 0, 0, 0, 0);
- issue_probereq(padapter, &(pmlmeext->sitesurvey_res.ssid[i]), NULL);
+ issue_probereq(padapter,
+ &pmlmeext->sitesurvey_res.ssid[i],
+ NULL, 0, 1, false);
}
if (pmlmeext->sitesurvey_res.scan_mode == SCAN_ACTIVE) {
/* IOT issue, When wifi_spec is not set, send one probe req without WPS IE. */
if (padapter->registrypriv.wifi_spec)
- issue_probereq(padapter, NULL, NULL);
+ issue_probereq(padapter, NULL, NULL, 0, 1, false);
else
issue_probereq_ex(padapter, NULL, NULL, 0, 0, 0, 0);
- issue_probereq(padapter, NULL, NULL);
+ issue_probereq(padapter, NULL, NULL, 0, 1, false);
}
}
}
diff --git a/drivers/staging/rtl8723bs/include/rtw_mlme_ext.h b/drivers/staging/rtl8723bs/include/rtw_mlme_ext.h
index a850675d5..ae4c4586f 100644
--- a/drivers/staging/rtl8723bs/include/rtw_mlme_ext.h
+++ b/drivers/staging/rtl8723bs/include/rtw_mlme_ext.h
@@ -539,7 +539,8 @@ void issue_probersp(struct adapter *padapter, unsigned char *da, u8 is_valid_p2p
void issue_assocreq(struct adapter *padapter);
void issue_asocrsp(struct adapter *padapter, unsigned short status, struct sta_info *pstat, int pkt_type);
void issue_auth(struct adapter *padapter, struct sta_info *psta, unsigned short status);
-void issue_probereq(struct adapter *padapter, struct ndis_802_11_ssid *pssid, u8 *da);
+int issue_probereq(struct adapter *padapter, struct ndis_802_11_ssid *pssid,
+ u8 *da, u8 ch, bool append_wps, bool wait_ack);
s32 issue_probereq_ex(struct adapter *padapter, struct ndis_802_11_ssid *pssid, u8 *da, u8 ch, bool append_wps, int try_cnt, int wait_ms);
int issue_nulldata(struct adapter *padapter, unsigned char *da, unsigned int power_mode, int try_cnt, int wait_ms);
s32 issue_nulldata_in_interrupt(struct adapter *padapter, u8 *da);
--
2.55.0