[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20251231072341.61195-1-saeed.b.67@gmail.com>
Date: Wed, 31 Dec 2025 10:53:41 +0330
From: "moradi.saeed" <saeed.b.67@...il.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: Johannes Berg <johannes.berg@...el.com>,
Michael Straube <straube.linux@...il.com>,
Dan Carpenter <dan.carpenter@...aro.org>,
linux-staging@...ts.linux.dev,
linux-kernel@...r.kernel.org,
"moradi.saeed" <saeed.b.67@...il.com>
Subject: [PATCH] staging: rtl8723bs: return -ENOENT for AP/Ad-Hoc get_station
The cfg80211 get_station callback must return -ENOENT when
station information is unavailable. The AP/Ad-Hoc path
currently returns success without filling station_info,
leading to invalid data exposure to userspace.
Fix this by returning -ENOENT for unimplemented modes.
Signed-off-by: moradi.saeed <saeed.b.67@...il.com>
---
drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
index 60edeae1cffe..c6562b8a59a6 100644
--- a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
+++ b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c
@@ -1011,7 +1011,9 @@ static int cfg80211_rtw_get_station(struct wiphy *wiphy,
check_fwstate(pmlmepriv, WIFI_ADHOC_MASTER_STATE) ||
check_fwstate(pmlmepriv, WIFI_AP_STATE)) &&
check_fwstate(pmlmepriv, _FW_LINKED)) {
- /* TODO: should acquire station info... */
+ ret = -ENOENT;
+ goto exit;
+
}
exit:
--
2.34.1
Powered by blists - more mailing lists