diff options
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/cfg.c | 7 | ||||
-rw-r--r-- | net/mac80211/iface.c | 2 | ||||
-rw-r--r-- | net/mac80211/mlme.c | 12 | ||||
-rw-r--r-- | net/mac80211/rx.c | 5 | ||||
-rw-r--r-- | net/mac80211/status.c | 2 | ||||
-rw-r--r-- | net/mac80211/tx.c | 4 |
6 files changed, 21 insertions, 11 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 51622333d460..818aa0060349 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -2891,7 +2891,7 @@ cfg80211_beacon_dup(struct cfg80211_beacon_data *beacon) | |||
2891 | 2891 | ||
2892 | len = beacon->head_len + beacon->tail_len + beacon->beacon_ies_len + | 2892 | len = beacon->head_len + beacon->tail_len + beacon->beacon_ies_len + |
2893 | beacon->proberesp_ies_len + beacon->assocresp_ies_len + | 2893 | beacon->proberesp_ies_len + beacon->assocresp_ies_len + |
2894 | beacon->probe_resp_len; | 2894 | beacon->probe_resp_len + beacon->lci_len + beacon->civicloc_len; |
2895 | 2895 | ||
2896 | new_beacon = kzalloc(sizeof(*new_beacon) + len, GFP_KERNEL); | 2896 | new_beacon = kzalloc(sizeof(*new_beacon) + len, GFP_KERNEL); |
2897 | if (!new_beacon) | 2897 | if (!new_beacon) |
@@ -2934,8 +2934,9 @@ cfg80211_beacon_dup(struct cfg80211_beacon_data *beacon) | |||
2934 | memcpy(pos, beacon->probe_resp, beacon->probe_resp_len); | 2934 | memcpy(pos, beacon->probe_resp, beacon->probe_resp_len); |
2935 | pos += beacon->probe_resp_len; | 2935 | pos += beacon->probe_resp_len; |
2936 | } | 2936 | } |
2937 | if (beacon->ftm_responder) | 2937 | |
2938 | new_beacon->ftm_responder = beacon->ftm_responder; | 2938 | /* might copy -1, meaning no changes requested */ |
2939 | new_beacon->ftm_responder = beacon->ftm_responder; | ||
2939 | if (beacon->lci) { | 2940 | if (beacon->lci) { |
2940 | new_beacon->lci_len = beacon->lci_len; | 2941 | new_beacon->lci_len = beacon->lci_len; |
2941 | new_beacon->lci = pos; | 2942 | new_beacon->lci = pos; |
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c index 5836ddeac9e3..5f3c81e705c7 100644 --- a/net/mac80211/iface.c +++ b/net/mac80211/iface.c | |||
@@ -1015,6 +1015,8 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata, | |||
1015 | if (local->open_count == 0) | 1015 | if (local->open_count == 0) |
1016 | ieee80211_clear_tx_pending(local); | 1016 | ieee80211_clear_tx_pending(local); |
1017 | 1017 | ||
1018 | sdata->vif.bss_conf.beacon_int = 0; | ||
1019 | |||
1018 | /* | 1020 | /* |
1019 | * If the interface goes down while suspended, presumably because | 1021 | * If the interface goes down while suspended, presumably because |
1020 | * the device was unplugged and that happens before our resume, | 1022 | * the device was unplugged and that happens before our resume, |
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c index d2bc8d57c87e..bcf5ffc1567a 100644 --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c | |||
@@ -2766,6 +2766,7 @@ static bool ieee80211_mark_sta_auth(struct ieee80211_sub_if_data *sdata, | |||
2766 | { | 2766 | { |
2767 | struct ieee80211_if_managed *ifmgd = &sdata->u.mgd; | 2767 | struct ieee80211_if_managed *ifmgd = &sdata->u.mgd; |
2768 | struct sta_info *sta; | 2768 | struct sta_info *sta; |
2769 | bool result = true; | ||
2769 | 2770 | ||
2770 | sdata_info(sdata, "authenticated\n"); | 2771 | sdata_info(sdata, "authenticated\n"); |
2771 | ifmgd->auth_data->done = true; | 2772 | ifmgd->auth_data->done = true; |
@@ -2778,15 +2779,18 @@ static bool ieee80211_mark_sta_auth(struct ieee80211_sub_if_data *sdata, | |||
2778 | sta = sta_info_get(sdata, bssid); | 2779 | sta = sta_info_get(sdata, bssid); |
2779 | if (!sta) { | 2780 | if (!sta) { |
2780 | WARN_ONCE(1, "%s: STA %pM not found", sdata->name, bssid); | 2781 | WARN_ONCE(1, "%s: STA %pM not found", sdata->name, bssid); |
2781 | return false; | 2782 | result = false; |
2783 | goto out; | ||
2782 | } | 2784 | } |
2783 | if (sta_info_move_state(sta, IEEE80211_STA_AUTH)) { | 2785 | if (sta_info_move_state(sta, IEEE80211_STA_AUTH)) { |
2784 | sdata_info(sdata, "failed moving %pM to auth\n", bssid); | 2786 | sdata_info(sdata, "failed moving %pM to auth\n", bssid); |
2785 | return false; | 2787 | result = false; |
2788 | goto out; | ||
2786 | } | 2789 | } |
2787 | mutex_unlock(&sdata->local->sta_mtx); | ||
2788 | 2790 | ||
2789 | return true; | 2791 | out: |
2792 | mutex_unlock(&sdata->local->sta_mtx); | ||
2793 | return result; | ||
2790 | } | 2794 | } |
2791 | 2795 | ||
2792 | static void ieee80211_rx_mgmt_auth(struct ieee80211_sub_if_data *sdata, | 2796 | static void ieee80211_rx_mgmt_auth(struct ieee80211_sub_if_data *sdata, |
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 3bd3b5769797..428f7ad5f9b5 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c | |||
@@ -1403,6 +1403,7 @@ ieee80211_rx_h_check_dup(struct ieee80211_rx_data *rx) | |||
1403 | return RX_CONTINUE; | 1403 | return RX_CONTINUE; |
1404 | 1404 | ||
1405 | if (ieee80211_is_ctl(hdr->frame_control) || | 1405 | if (ieee80211_is_ctl(hdr->frame_control) || |
1406 | ieee80211_is_nullfunc(hdr->frame_control) || | ||
1406 | ieee80211_is_qos_nullfunc(hdr->frame_control) || | 1407 | ieee80211_is_qos_nullfunc(hdr->frame_control) || |
1407 | is_multicast_ether_addr(hdr->addr1)) | 1408 | is_multicast_ether_addr(hdr->addr1)) |
1408 | return RX_CONTINUE; | 1409 | return RX_CONTINUE; |
@@ -3063,7 +3064,7 @@ ieee80211_rx_h_action(struct ieee80211_rx_data *rx) | |||
3063 | cfg80211_sta_opmode_change_notify(sdata->dev, | 3064 | cfg80211_sta_opmode_change_notify(sdata->dev, |
3064 | rx->sta->addr, | 3065 | rx->sta->addr, |
3065 | &sta_opmode, | 3066 | &sta_opmode, |
3066 | GFP_KERNEL); | 3067 | GFP_ATOMIC); |
3067 | goto handled; | 3068 | goto handled; |
3068 | } | 3069 | } |
3069 | case WLAN_HT_ACTION_NOTIFY_CHANWIDTH: { | 3070 | case WLAN_HT_ACTION_NOTIFY_CHANWIDTH: { |
@@ -3100,7 +3101,7 @@ ieee80211_rx_h_action(struct ieee80211_rx_data *rx) | |||
3100 | cfg80211_sta_opmode_change_notify(sdata->dev, | 3101 | cfg80211_sta_opmode_change_notify(sdata->dev, |
3101 | rx->sta->addr, | 3102 | rx->sta->addr, |
3102 | &sta_opmode, | 3103 | &sta_opmode, |
3103 | GFP_KERNEL); | 3104 | GFP_ATOMIC); |
3104 | goto handled; | 3105 | goto handled; |
3105 | } | 3106 | } |
3106 | default: | 3107 | default: |
diff --git a/net/mac80211/status.c b/net/mac80211/status.c index aa4afbf0abaf..a794ca729000 100644 --- a/net/mac80211/status.c +++ b/net/mac80211/status.c | |||
@@ -964,6 +964,8 @@ void ieee80211_tx_status_ext(struct ieee80211_hw *hw, | |||
964 | /* Track when last TDLS packet was ACKed */ | 964 | /* Track when last TDLS packet was ACKed */ |
965 | if (test_sta_flag(sta, WLAN_STA_TDLS_PEER_AUTH)) | 965 | if (test_sta_flag(sta, WLAN_STA_TDLS_PEER_AUTH)) |
966 | sta->status_stats.last_tdls_pkt_time = jiffies; | 966 | sta->status_stats.last_tdls_pkt_time = jiffies; |
967 | } else if (test_sta_flag(sta, WLAN_STA_PS_STA)) { | ||
968 | return; | ||
967 | } else { | 969 | } else { |
968 | ieee80211_lost_packet(sta, info); | 970 | ieee80211_lost_packet(sta, info); |
969 | } | 971 | } |
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c index e0ccee23fbcd..1f536ba573b4 100644 --- a/net/mac80211/tx.c +++ b/net/mac80211/tx.c | |||
@@ -439,8 +439,8 @@ ieee80211_tx_h_multicast_ps_buf(struct ieee80211_tx_data *tx) | |||
439 | if (ieee80211_hw_check(&tx->local->hw, QUEUE_CONTROL)) | 439 | if (ieee80211_hw_check(&tx->local->hw, QUEUE_CONTROL)) |
440 | info->hw_queue = tx->sdata->vif.cab_queue; | 440 | info->hw_queue = tx->sdata->vif.cab_queue; |
441 | 441 | ||
442 | /* no stations in PS mode */ | 442 | /* no stations in PS mode and no buffered packets */ |
443 | if (!atomic_read(&ps->num_sta_ps)) | 443 | if (!atomic_read(&ps->num_sta_ps) && skb_queue_empty(&ps->bc_buf)) |
444 | return TX_CONTINUE; | 444 | return TX_CONTINUE; |
445 | 445 | ||
446 | info->flags |= IEEE80211_TX_CTL_SEND_AFTER_DTIM; | 446 | info->flags |= IEEE80211_TX_CTL_SEND_AFTER_DTIM; |