|
@@ -2521,6 +2521,35 @@ done:
|
|
|
return err;
|
|
|
}
|
|
|
|
|
|
+static int
|
|
|
+brcmf_cfg80211_dump_station(struct wiphy *wiphy, struct net_device *ndev,
|
|
|
+ int idx, u8 *mac, struct station_info *sinfo)
|
|
|
+{
|
|
|
+ struct brcmf_cfg80211_info *cfg = wiphy_to_cfg(wiphy);
|
|
|
+ struct brcmf_if *ifp = netdev_priv(ndev);
|
|
|
+ s32 err;
|
|
|
+
|
|
|
+ brcmf_dbg(TRACE, "Enter, idx %d\n", idx);
|
|
|
+
|
|
|
+ if (idx == 0) {
|
|
|
+ cfg->assoclist.count = cpu_to_le32(BRCMF_MAX_ASSOCLIST);
|
|
|
+ err = brcmf_fil_cmd_data_get(ifp, BRCMF_C_GET_ASSOCLIST,
|
|
|
+ &cfg->assoclist,
|
|
|
+ sizeof(cfg->assoclist));
|
|
|
+ if (err) {
|
|
|
+ brcmf_err("BRCMF_C_GET_ASSOCLIST unsupported, err=%d\n",
|
|
|
+ err);
|
|
|
+ cfg->assoclist.count = 0;
|
|
|
+ return -EOPNOTSUPP;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (idx < le32_to_cpu(cfg->assoclist.count)) {
|
|
|
+ memcpy(mac, cfg->assoclist.mac[idx], ETH_ALEN);
|
|
|
+ return brcmf_cfg80211_get_station(wiphy, ndev, mac, sinfo);
|
|
|
+ }
|
|
|
+ return -ENOENT;
|
|
|
+}
|
|
|
+
|
|
|
static s32
|
|
|
brcmf_cfg80211_set_power_mgmt(struct wiphy *wiphy, struct net_device *ndev,
|
|
|
bool enabled, s32 timeout)
|
|
@@ -4620,6 +4649,7 @@ static struct cfg80211_ops wl_cfg80211_ops = {
|
|
|
.join_ibss = brcmf_cfg80211_join_ibss,
|
|
|
.leave_ibss = brcmf_cfg80211_leave_ibss,
|
|
|
.get_station = brcmf_cfg80211_get_station,
|
|
|
+ .dump_station = brcmf_cfg80211_dump_station,
|
|
|
.set_tx_power = brcmf_cfg80211_set_tx_power,
|
|
|
.get_tx_power = brcmf_cfg80211_get_tx_power,
|
|
|
.add_key = brcmf_cfg80211_add_key,
|