mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
This commit is contained in:
commit
874239f51f
10 changed files with 58 additions and 23 deletions
|
|
@ -225,9 +225,9 @@ KEY_OPS(key);
|
|||
key, &key_##name##_ops);
|
||||
|
||||
void ieee80211_debugfs_key_add(struct ieee80211_key *key)
|
||||
{
|
||||
{
|
||||
static int keycount;
|
||||
char buf[50];
|
||||
char buf[100];
|
||||
struct sta_info *sta;
|
||||
|
||||
if (!key->local->debugfs.keys)
|
||||
|
|
@ -244,7 +244,8 @@ void ieee80211_debugfs_key_add(struct ieee80211_key *key)
|
|||
|
||||
sta = key->sta;
|
||||
if (sta) {
|
||||
sprintf(buf, "../../stations/%pM", sta->sta.addr);
|
||||
sprintf(buf, "../../netdev:%s/stations/%pM",
|
||||
sta->sdata->name, sta->sta.addr);
|
||||
key->debugfs.stalink =
|
||||
debugfs_create_symlink("station", key->debugfs.dir, buf);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -81,6 +81,7 @@ static void __ieee80211_sta_join_ibss(struct ieee80211_sub_if_data *sdata,
|
|||
|
||||
sdata->drop_unencrypted = capability & WLAN_CAPABILITY_PRIVACY ? 1 : 0;
|
||||
|
||||
local->oper_channel = chan;
|
||||
channel_type = ifibss->channel_type;
|
||||
if (channel_type > NL80211_CHAN_HT20 &&
|
||||
!cfg80211_can_beacon_sec_chan(local->hw.wiphy, chan, channel_type))
|
||||
|
|
|
|||
|
|
@ -1321,6 +1321,7 @@ u32 __ieee80211_recalc_idle(struct ieee80211_local *local)
|
|||
continue;
|
||||
}
|
||||
/* count everything else */
|
||||
sdata->vif.bss_conf.idle = false;
|
||||
count++;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -119,12 +119,12 @@ static int mesh_path_sel_frame_tx(enum mpath_frame_type action, u8 flags,
|
|||
int hdr_len = offsetof(struct ieee80211_mgmt, u.action.u.mesh_action) +
|
||||
sizeof(mgmt->u.action.u.mesh_action);
|
||||
|
||||
skb = dev_alloc_skb(local->hw.extra_tx_headroom +
|
||||
skb = dev_alloc_skb(local->tx_headroom +
|
||||
hdr_len +
|
||||
2 + 37); /* max HWMP IE */
|
||||
if (!skb)
|
||||
return -1;
|
||||
skb_reserve(skb, local->hw.extra_tx_headroom);
|
||||
skb_reserve(skb, local->tx_headroom);
|
||||
mgmt = (struct ieee80211_mgmt *) skb_put(skb, hdr_len);
|
||||
memset(mgmt, 0, hdr_len);
|
||||
mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT |
|
||||
|
|
@ -250,12 +250,12 @@ int mesh_path_error_tx(u8 ttl, u8 *target, __le32 target_sn,
|
|||
if (time_before(jiffies, ifmsh->next_perr))
|
||||
return -EAGAIN;
|
||||
|
||||
skb = dev_alloc_skb(local->hw.extra_tx_headroom +
|
||||
skb = dev_alloc_skb(local->tx_headroom +
|
||||
hdr_len +
|
||||
2 + 15 /* PERR IE */);
|
||||
if (!skb)
|
||||
return -1;
|
||||
skb_reserve(skb, local->tx_headroom + local->hw.extra_tx_headroom);
|
||||
skb_reserve(skb, local->tx_headroom);
|
||||
mgmt = (struct ieee80211_mgmt *) skb_put(skb, hdr_len);
|
||||
memset(mgmt, 0, hdr_len);
|
||||
mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT |
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@ static int mesh_plink_frame_tx(struct ieee80211_sub_if_data *sdata,
|
|||
int hdr_len = offsetof(struct ieee80211_mgmt, u.action.u.self_prot) +
|
||||
sizeof(mgmt->u.action.u.self_prot);
|
||||
|
||||
skb = dev_alloc_skb(local->hw.extra_tx_headroom +
|
||||
skb = dev_alloc_skb(local->tx_headroom +
|
||||
hdr_len +
|
||||
2 + /* capability info */
|
||||
2 + /* AID */
|
||||
|
|
@ -186,7 +186,7 @@ static int mesh_plink_frame_tx(struct ieee80211_sub_if_data *sdata,
|
|||
sdata->u.mesh.ie_len);
|
||||
if (!skb)
|
||||
return -1;
|
||||
skb_reserve(skb, local->hw.extra_tx_headroom);
|
||||
skb_reserve(skb, local->tx_headroom);
|
||||
mgmt = (struct ieee80211_mgmt *) skb_put(skb, hdr_len);
|
||||
memset(mgmt, 0, hdr_len);
|
||||
mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT |
|
||||
|
|
|
|||
|
|
@ -2759,7 +2759,6 @@ int ieee80211_mgd_deauth(struct ieee80211_sub_if_data *sdata,
|
|||
{
|
||||
struct ieee80211_local *local = sdata->local;
|
||||
struct ieee80211_if_managed *ifmgd = &sdata->u.mgd;
|
||||
struct ieee80211_work *wk;
|
||||
u8 bssid[ETH_ALEN];
|
||||
bool assoc_bss = false;
|
||||
|
||||
|
|
@ -2772,30 +2771,47 @@ int ieee80211_mgd_deauth(struct ieee80211_sub_if_data *sdata,
|
|||
assoc_bss = true;
|
||||
} else {
|
||||
bool not_auth_yet = false;
|
||||
struct ieee80211_work *tmp, *wk = NULL;
|
||||
|
||||
mutex_unlock(&ifmgd->mtx);
|
||||
|
||||
mutex_lock(&local->mtx);
|
||||
list_for_each_entry(wk, &local->work_list, list) {
|
||||
if (wk->sdata != sdata)
|
||||
list_for_each_entry(tmp, &local->work_list, list) {
|
||||
if (tmp->sdata != sdata)
|
||||
continue;
|
||||
|
||||
if (wk->type != IEEE80211_WORK_DIRECT_PROBE &&
|
||||
wk->type != IEEE80211_WORK_AUTH &&
|
||||
wk->type != IEEE80211_WORK_ASSOC &&
|
||||
wk->type != IEEE80211_WORK_ASSOC_BEACON_WAIT)
|
||||
if (tmp->type != IEEE80211_WORK_DIRECT_PROBE &&
|
||||
tmp->type != IEEE80211_WORK_AUTH &&
|
||||
tmp->type != IEEE80211_WORK_ASSOC &&
|
||||
tmp->type != IEEE80211_WORK_ASSOC_BEACON_WAIT)
|
||||
continue;
|
||||
|
||||
if (memcmp(req->bss->bssid, wk->filter_ta, ETH_ALEN))
|
||||
if (memcmp(req->bss->bssid, tmp->filter_ta, ETH_ALEN))
|
||||
continue;
|
||||
|
||||
not_auth_yet = wk->type == IEEE80211_WORK_DIRECT_PROBE;
|
||||
list_del_rcu(&wk->list);
|
||||
free_work(wk);
|
||||
not_auth_yet = tmp->type == IEEE80211_WORK_DIRECT_PROBE;
|
||||
list_del_rcu(&tmp->list);
|
||||
synchronize_rcu();
|
||||
wk = tmp;
|
||||
break;
|
||||
}
|
||||
mutex_unlock(&local->mtx);
|
||||
|
||||
if (wk && wk->type == IEEE80211_WORK_ASSOC) {
|
||||
/* clean up dummy sta & TX sync */
|
||||
sta_info_destroy_addr(wk->sdata, wk->filter_ta);
|
||||
if (wk->assoc.synced)
|
||||
drv_finish_tx_sync(local, wk->sdata,
|
||||
wk->filter_ta,
|
||||
IEEE80211_TX_SYNC_ASSOC);
|
||||
} else if (wk && wk->type == IEEE80211_WORK_AUTH) {
|
||||
if (wk->probe_auth.synced)
|
||||
drv_finish_tx_sync(local, wk->sdata,
|
||||
wk->filter_ta,
|
||||
IEEE80211_TX_SYNC_AUTH);
|
||||
}
|
||||
kfree(wk);
|
||||
|
||||
/*
|
||||
* If somebody requests authentication and we haven't
|
||||
* sent out an auth frame yet there's no need to send
|
||||
|
|
|
|||
Loading…
Reference in a new issue