diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/cfg80211.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/wmi.c | 43 | ||||
-rw-r--r-- | drivers/net/wireless/ath/wil6210/wmi.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c | 18 | ||||
-rw-r--r-- | drivers/net/wireless/libertas/cfg.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/cfg80211.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/scan.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/orinoco/scan.c | 14 | ||||
-rw-r--r-- | drivers/net/wireless/rndis_wlan.c | 14 | ||||
-rw-r--r-- | drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c | 1 | ||||
-rw-r--r-- | drivers/staging/wlan-ng/cfg80211.c | 1 |
11 files changed, 46 insertions, 54 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/cfg80211.c b/drivers/net/wireless/ath/ath6kl/cfg80211.c index e535807c3d89..ba60e37213eb 100644 --- a/drivers/net/wireless/ath/ath6kl/cfg80211.c +++ b/drivers/net/wireless/ath/ath6kl/cfg80211.c | |||
@@ -717,6 +717,7 @@ ath6kl_add_bss_if_needed(struct ath6kl_vif *vif, | |||
717 | memcpy(ie + 2, vif->ssid, vif->ssid_len); | 717 | memcpy(ie + 2, vif->ssid, vif->ssid_len); |
718 | memcpy(ie + 2 + vif->ssid_len, beacon_ie, beacon_ie_len); | 718 | memcpy(ie + 2 + vif->ssid_len, beacon_ie, beacon_ie_len); |
719 | bss = cfg80211_inform_bss(ar->wiphy, chan, | 719 | bss = cfg80211_inform_bss(ar->wiphy, chan, |
720 | CFG80211_BSS_FTYPE_UNKNOWN, | ||
720 | bssid, 0, cap_val, 100, | 721 | bssid, 0, cap_val, 100, |
721 | ie, 2 + vif->ssid_len + beacon_ie_len, | 722 | ie, 2 + vif->ssid_len + beacon_ie_len, |
722 | 0, GFP_KERNEL); | 723 | 0, GFP_KERNEL); |
diff --git a/drivers/net/wireless/ath/ath6kl/wmi.c b/drivers/net/wireless/ath/ath6kl/wmi.c index 77fcca1f5bd6..b921005ad7ee 100644 --- a/drivers/net/wireless/ath/ath6kl/wmi.c +++ b/drivers/net/wireless/ath/ath6kl/wmi.c | |||
@@ -1092,7 +1092,6 @@ static int ath6kl_wmi_bssinfo_event_rx(struct wmi *wmi, u8 *datap, int len, | |||
1092 | u8 *buf; | 1092 | u8 *buf; |
1093 | struct ieee80211_channel *channel; | 1093 | struct ieee80211_channel *channel; |
1094 | struct ath6kl *ar = wmi->parent_dev; | 1094 | struct ath6kl *ar = wmi->parent_dev; |
1095 | struct ieee80211_mgmt *mgmt; | ||
1096 | struct cfg80211_bss *bss; | 1095 | struct cfg80211_bss *bss; |
1097 | 1096 | ||
1098 | if (len <= sizeof(struct wmi_bss_info_hdr2)) | 1097 | if (len <= sizeof(struct wmi_bss_info_hdr2)) |
@@ -1138,39 +1137,15 @@ static int ath6kl_wmi_bssinfo_event_rx(struct wmi *wmi, u8 *datap, int len, | |||
1138 | } | 1137 | } |
1139 | } | 1138 | } |
1140 | 1139 | ||
1141 | /* | 1140 | bss = cfg80211_inform_bss(ar->wiphy, channel, |
1142 | * In theory, use of cfg80211_inform_bss() would be more natural here | 1141 | bih->frame_type == BEACON_FTYPE ? |
1143 | * since we do not have the full frame. However, at least for now, | 1142 | CFG80211_BSS_FTYPE_BEACON : |
1144 | * cfg80211 can only distinguish Beacon and Probe Response frames from | 1143 | CFG80211_BSS_FTYPE_PRESP, |
1145 | * each other when using cfg80211_inform_bss_frame(), so let's build a | 1144 | bih->bssid, get_unaligned_le64((__le64 *)buf), |
1146 | * fake IEEE 802.11 header to be able to take benefit of this. | 1145 | get_unaligned_le16(((__le16 *)buf) + 5), |
1147 | */ | 1146 | get_unaligned_le16(((__le16 *)buf) + 4), |
1148 | mgmt = kmalloc(24 + len, GFP_ATOMIC); | 1147 | buf + 8 + 2 + 2, len - 8 - 2 - 2, |
1149 | if (mgmt == NULL) | 1148 | (bih->snr - 95) * 100, GFP_ATOMIC); |
1150 | return -EINVAL; | ||
1151 | |||
1152 | if (bih->frame_type == BEACON_FTYPE) { | ||
1153 | mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | | ||
1154 | IEEE80211_STYPE_BEACON); | ||
1155 | memset(mgmt->da, 0xff, ETH_ALEN); | ||
1156 | } else { | ||
1157 | struct net_device *dev = vif->ndev; | ||
1158 | |||
1159 | mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | | ||
1160 | IEEE80211_STYPE_PROBE_RESP); | ||
1161 | memcpy(mgmt->da, dev->dev_addr, ETH_ALEN); | ||
1162 | } | ||
1163 | mgmt->duration = cpu_to_le16(0); | ||
1164 | memcpy(mgmt->sa, bih->bssid, ETH_ALEN); | ||
1165 | memcpy(mgmt->bssid, bih->bssid, ETH_ALEN); | ||
1166 | mgmt->seq_ctrl = cpu_to_le16(0); | ||
1167 | |||
1168 | memcpy(&mgmt->u.beacon, buf, len); | ||
1169 | |||
1170 | bss = cfg80211_inform_bss_frame(ar->wiphy, channel, mgmt, | ||
1171 | 24 + len, (bih->snr - 95) * 100, | ||
1172 | GFP_ATOMIC); | ||
1173 | kfree(mgmt); | ||
1174 | if (bss == NULL) | 1149 | if (bss == NULL) |
1175 | return -ENOMEM; | 1150 | return -ENOMEM; |
1176 | cfg80211_put_bss(ar->wiphy, bss); | 1151 | cfg80211_put_bss(ar->wiphy, bss); |
diff --git a/drivers/net/wireless/ath/wil6210/wmi.c b/drivers/net/wireless/ath/wil6210/wmi.c index 335bc38325db..960b66fc1430 100644 --- a/drivers/net/wireless/ath/wil6210/wmi.c +++ b/drivers/net/wireless/ath/wil6210/wmi.c | |||
@@ -346,7 +346,7 @@ static void wmi_evt_rx_mgmt(struct wil6210_priv *wil, int id, void *d, int len) | |||
346 | rx_mgmt_frame->bssid); | 346 | rx_mgmt_frame->bssid); |
347 | cfg80211_put_bss(wiphy, bss); | 347 | cfg80211_put_bss(wiphy, bss); |
348 | } else { | 348 | } else { |
349 | wil_err(wil, "cfg80211_inform_bss() failed\n"); | 349 | wil_err(wil, "cfg80211_inform_bss_frame() failed\n"); |
350 | } | 350 | } |
351 | } else { | 351 | } else { |
352 | cfg80211_rx_mgmt(wil->wdev, freq, signal, | 352 | cfg80211_rx_mgmt(wil->wdev, freq, signal, |
diff --git a/drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c b/drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c index 02fe706fc9ec..12a60ca1462a 100644 --- a/drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c +++ b/drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c | |||
@@ -2394,9 +2394,13 @@ static s32 brcmf_inform_single_bss(struct brcmf_cfg80211_info *cfg, | |||
2394 | brcmf_dbg(CONN, "Beacon interval: %d\n", notify_interval); | 2394 | brcmf_dbg(CONN, "Beacon interval: %d\n", notify_interval); |
2395 | brcmf_dbg(CONN, "Signal: %d\n", notify_signal); | 2395 | brcmf_dbg(CONN, "Signal: %d\n", notify_signal); |
2396 | 2396 | ||
2397 | bss = cfg80211_inform_bss(wiphy, notify_channel, (const u8 *)bi->BSSID, | 2397 | bss = cfg80211_inform_bss(wiphy, notify_channel, |
2398 | 0, notify_capability, notify_interval, notify_ie, | 2398 | CFG80211_BSS_FTYPE_UNKNOWN, |
2399 | notify_ielen, notify_signal, GFP_KERNEL); | 2399 | (const u8 *)bi->BSSID, |
2400 | 0, notify_capability, | ||
2401 | notify_interval, notify_ie, | ||
2402 | notify_ielen, notify_signal, | ||
2403 | GFP_KERNEL); | ||
2400 | 2404 | ||
2401 | if (!bss) | 2405 | if (!bss) |
2402 | return -ENOMEM; | 2406 | return -ENOMEM; |
@@ -2498,9 +2502,11 @@ static s32 wl_inform_ibss(struct brcmf_cfg80211_info *cfg, | |||
2498 | brcmf_dbg(CONN, "beacon interval: %d\n", notify_interval); | 2502 | brcmf_dbg(CONN, "beacon interval: %d\n", notify_interval); |
2499 | brcmf_dbg(CONN, "signal: %d\n", notify_signal); | 2503 | brcmf_dbg(CONN, "signal: %d\n", notify_signal); |
2500 | 2504 | ||
2501 | bss = cfg80211_inform_bss(wiphy, notify_channel, bssid, | 2505 | bss = cfg80211_inform_bss(wiphy, notify_channel, |
2502 | 0, notify_capability, notify_interval, | 2506 | CFG80211_BSS_FTYPE_UNKNOWN, bssid, 0, |
2503 | notify_ie, notify_ielen, notify_signal, GFP_KERNEL); | 2507 | notify_capability, notify_interval, |
2508 | notify_ie, notify_ielen, notify_signal, | ||
2509 | GFP_KERNEL); | ||
2504 | 2510 | ||
2505 | if (!bss) { | 2511 | if (!bss) { |
2506 | err = -ENOMEM; | 2512 | err = -ENOMEM; |
diff --git a/drivers/net/wireless/libertas/cfg.c b/drivers/net/wireless/libertas/cfg.c index 47a998d8f99e..22884ba7d6cc 100644 --- a/drivers/net/wireless/libertas/cfg.c +++ b/drivers/net/wireless/libertas/cfg.c | |||
@@ -653,6 +653,7 @@ static int lbs_ret_scan(struct lbs_private *priv, unsigned long dummy, | |||
653 | if (channel && | 653 | if (channel && |
654 | !(channel->flags & IEEE80211_CHAN_DISABLED)) { | 654 | !(channel->flags & IEEE80211_CHAN_DISABLED)) { |
655 | bss = cfg80211_inform_bss(wiphy, channel, | 655 | bss = cfg80211_inform_bss(wiphy, channel, |
656 | CFG80211_BSS_FTYPE_UNKNOWN, | ||
656 | bssid, get_unaligned_le64(tsfdesc), | 657 | bssid, get_unaligned_le64(tsfdesc), |
657 | capa, intvl, ie, ielen, | 658 | capa, intvl, ie, ielen, |
658 | LBS_SCAN_RSSI_TO_MBM(rssi), | 659 | LBS_SCAN_RSSI_TO_MBM(rssi), |
@@ -1754,6 +1755,7 @@ static void lbs_join_post(struct lbs_private *priv, | |||
1754 | 1755 | ||
1755 | bss = cfg80211_inform_bss(priv->wdev->wiphy, | 1756 | bss = cfg80211_inform_bss(priv->wdev->wiphy, |
1756 | params->chandef.chan, | 1757 | params->chandef.chan, |
1758 | CFG80211_BSS_FTYPE_UNKNOWN, | ||
1757 | bssid, | 1759 | bssid, |
1758 | 0, | 1760 | 0, |
1759 | capability, | 1761 | capability, |
diff --git a/drivers/net/wireless/mwifiex/cfg80211.c b/drivers/net/wireless/mwifiex/cfg80211.c index e2e6bf13c2d8..15f994f3b4ce 100644 --- a/drivers/net/wireless/mwifiex/cfg80211.c +++ b/drivers/net/wireless/mwifiex/cfg80211.c | |||
@@ -1557,6 +1557,7 @@ static int mwifiex_cfg80211_inform_ibss_bss(struct mwifiex_private *priv) | |||
1557 | band)); | 1557 | band)); |
1558 | 1558 | ||
1559 | bss = cfg80211_inform_bss(priv->wdev->wiphy, chan, | 1559 | bss = cfg80211_inform_bss(priv->wdev->wiphy, chan, |
1560 | CFG80211_BSS_FTYPE_UNKNOWN, | ||
1560 | bss_info.bssid, 0, WLAN_CAPABILITY_IBSS, | 1561 | bss_info.bssid, 0, WLAN_CAPABILITY_IBSS, |
1561 | 0, ie_buf, ie_len, 0, GFP_KERNEL); | 1562 | 0, ie_buf, ie_len, 0, GFP_KERNEL); |
1562 | cfg80211_put_bss(priv->wdev->wiphy, bss); | 1563 | cfg80211_put_bss(priv->wdev->wiphy, bss); |
diff --git a/drivers/net/wireless/mwifiex/scan.c b/drivers/net/wireless/mwifiex/scan.c index dee717a19ddb..195ef0ca343f 100644 --- a/drivers/net/wireless/mwifiex/scan.c +++ b/drivers/net/wireless/mwifiex/scan.c | |||
@@ -1719,7 +1719,8 @@ mwifiex_parse_single_response_buf(struct mwifiex_private *priv, u8 **bss_info, | |||
1719 | 1719 | ||
1720 | if (chan && !(chan->flags & IEEE80211_CHAN_DISABLED)) { | 1720 | if (chan && !(chan->flags & IEEE80211_CHAN_DISABLED)) { |
1721 | bss = cfg80211_inform_bss(priv->wdev->wiphy, | 1721 | bss = cfg80211_inform_bss(priv->wdev->wiphy, |
1722 | chan, bssid, timestamp, | 1722 | chan, CFG80211_BSS_FTYPE_UNKNOWN, |
1723 | bssid, timestamp, | ||
1723 | cap_info_bitmap, beacon_period, | 1724 | cap_info_bitmap, beacon_period, |
1724 | ie_buf, ie_len, rssi, GFP_KERNEL); | 1725 | ie_buf, ie_len, rssi, GFP_KERNEL); |
1725 | bss_priv = (struct mwifiex_bss_priv *)bss->priv; | 1726 | bss_priv = (struct mwifiex_bss_priv *)bss->priv; |
diff --git a/drivers/net/wireless/orinoco/scan.c b/drivers/net/wireless/orinoco/scan.c index e175b9b8561b..2c66166add70 100644 --- a/drivers/net/wireless/orinoco/scan.c +++ b/drivers/net/wireless/orinoco/scan.c | |||
@@ -123,9 +123,10 @@ static void orinoco_add_hostscan_result(struct orinoco_private *priv, | |||
123 | beacon_interval = le16_to_cpu(bss->a.beacon_interv); | 123 | beacon_interval = le16_to_cpu(bss->a.beacon_interv); |
124 | signal = SIGNAL_TO_MBM(le16_to_cpu(bss->a.level)); | 124 | signal = SIGNAL_TO_MBM(le16_to_cpu(bss->a.level)); |
125 | 125 | ||
126 | cbss = cfg80211_inform_bss(wiphy, channel, bss->a.bssid, timestamp, | 126 | cbss = cfg80211_inform_bss(wiphy, channel, CFG80211_BSS_FTYPE_UNKNOWN, |
127 | capability, beacon_interval, ie_buf, ie_len, | 127 | bss->a.bssid, timestamp, capability, |
128 | signal, GFP_KERNEL); | 128 | beacon_interval, ie_buf, ie_len, signal, |
129 | GFP_KERNEL); | ||
129 | cfg80211_put_bss(wiphy, cbss); | 130 | cfg80211_put_bss(wiphy, cbss); |
130 | } | 131 | } |
131 | 132 | ||
@@ -156,9 +157,10 @@ void orinoco_add_extscan_result(struct orinoco_private *priv, | |||
156 | ie = bss->data; | 157 | ie = bss->data; |
157 | signal = SIGNAL_TO_MBM(bss->level); | 158 | signal = SIGNAL_TO_MBM(bss->level); |
158 | 159 | ||
159 | cbss = cfg80211_inform_bss(wiphy, channel, bss->bssid, timestamp, | 160 | cbss = cfg80211_inform_bss(wiphy, channel, CFG80211_BSS_FTYPE_UNKNOWN, |
160 | capability, beacon_interval, ie, ie_len, | 161 | bss->bssid, timestamp, capability, |
161 | signal, GFP_KERNEL); | 162 | beacon_interval, ie, ie_len, signal, |
163 | GFP_KERNEL); | ||
162 | cfg80211_put_bss(wiphy, cbss); | 164 | cfg80211_put_bss(wiphy, cbss); |
163 | } | 165 | } |
164 | 166 | ||
diff --git a/drivers/net/wireless/rndis_wlan.c b/drivers/net/wireless/rndis_wlan.c index d2a9a08210be..1a4facd1fbf3 100644 --- a/drivers/net/wireless/rndis_wlan.c +++ b/drivers/net/wireless/rndis_wlan.c | |||
@@ -2022,9 +2022,10 @@ static bool rndis_bss_info_update(struct usbnet *usbdev, | |||
2022 | capability = le16_to_cpu(fixed->capabilities); | 2022 | capability = le16_to_cpu(fixed->capabilities); |
2023 | beacon_interval = le16_to_cpu(fixed->beacon_interval); | 2023 | beacon_interval = le16_to_cpu(fixed->beacon_interval); |
2024 | 2024 | ||
2025 | bss = cfg80211_inform_bss(priv->wdev.wiphy, channel, bssid->mac, | 2025 | bss = cfg80211_inform_bss(priv->wdev.wiphy, channel, |
2026 | timestamp, capability, beacon_interval, ie, ie_len, signal, | 2026 | CFG80211_BSS_FTYPE_UNKNOWN, bssid->mac, |
2027 | GFP_KERNEL); | 2027 | timestamp, capability, beacon_interval, |
2028 | ie, ie_len, signal, GFP_KERNEL); | ||
2028 | cfg80211_put_bss(priv->wdev.wiphy, bss); | 2029 | cfg80211_put_bss(priv->wdev.wiphy, bss); |
2029 | 2030 | ||
2030 | return (bss != NULL); | 2031 | return (bss != NULL); |
@@ -2711,9 +2712,10 @@ static void rndis_wlan_craft_connected_bss(struct usbnet *usbdev, u8 *bssid, | |||
2711 | bssid, (u32)timestamp, capability, beacon_period, ie_len, | 2712 | bssid, (u32)timestamp, capability, beacon_period, ie_len, |
2712 | ssid.essid, signal); | 2713 | ssid.essid, signal); |
2713 | 2714 | ||
2714 | bss = cfg80211_inform_bss(priv->wdev.wiphy, channel, bssid, | 2715 | bss = cfg80211_inform_bss(priv->wdev.wiphy, channel, |
2715 | timestamp, capability, beacon_period, ie_buf, ie_len, | 2716 | CFG80211_BSS_FTYPE_UNKNOWN, bssid, |
2716 | signal, GFP_KERNEL); | 2717 | timestamp, capability, beacon_period, |
2718 | ie_buf, ie_len, signal, GFP_KERNEL); | ||
2717 | cfg80211_put_bss(priv->wdev.wiphy, bss); | 2719 | cfg80211_put_bss(priv->wdev.wiphy, bss); |
2718 | } | 2720 | } |
2719 | 2721 | ||
diff --git a/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c index 2d6d7d1a5b7d..8b0ccb5c5fc4 100644 --- a/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c +++ b/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c | |||
@@ -279,6 +279,7 @@ static int rtw_cfg80211_inform_bss(struct rtw_adapter *padapter, | |||
279 | } | 279 | } |
280 | 280 | ||
281 | bss = cfg80211_inform_bss(wiphy, notify_channel, | 281 | bss = cfg80211_inform_bss(wiphy, notify_channel, |
282 | CFG80211_BSS_FTYPE_UNKNOWN, | ||
282 | pnetwork->network.MacAddress, | 283 | pnetwork->network.MacAddress, |
283 | pnetwork->network.tsf, | 284 | pnetwork->network.tsf, |
284 | pnetwork->network.capability, | 285 | pnetwork->network.capability, |
diff --git a/drivers/staging/wlan-ng/cfg80211.c b/drivers/staging/wlan-ng/cfg80211.c index 3727f6d25cf1..8942dcb44180 100644 --- a/drivers/staging/wlan-ng/cfg80211.c +++ b/drivers/staging/wlan-ng/cfg80211.c | |||
@@ -422,6 +422,7 @@ static int prism2_scan(struct wiphy *wiphy, | |||
422 | IEEE80211_BAND_2GHZ); | 422 | IEEE80211_BAND_2GHZ); |
423 | bss = cfg80211_inform_bss(wiphy, | 423 | bss = cfg80211_inform_bss(wiphy, |
424 | ieee80211_get_channel(wiphy, freq), | 424 | ieee80211_get_channel(wiphy, freq), |
425 | CFG80211_BSS_FTYPE_UNKNOWN, | ||
425 | (const u8 *) &(msg2.bssid.data.data), | 426 | (const u8 *) &(msg2.bssid.data.data), |
426 | msg2.timestamp.data, msg2.capinfo.data, | 427 | msg2.timestamp.data, msg2.capinfo.data, |
427 | msg2.beaconperiod.data, | 428 | msg2.beaconperiod.data, |