diff options
Diffstat (limited to 'net/mac80211/iface.c')
| -rw-r--r-- | net/mac80211/iface.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c index b4ac596a7cb7..84cef600c573 100644 --- a/net/mac80211/iface.c +++ b/net/mac80211/iface.c | |||
| @@ -522,6 +522,12 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up) | |||
| 522 | memcpy(sdata->vif.hw_queue, master->vif.hw_queue, | 522 | memcpy(sdata->vif.hw_queue, master->vif.hw_queue, |
| 523 | sizeof(sdata->vif.hw_queue)); | 523 | sizeof(sdata->vif.hw_queue)); |
| 524 | sdata->vif.bss_conf.chandef = master->vif.bss_conf.chandef; | 524 | sdata->vif.bss_conf.chandef = master->vif.bss_conf.chandef; |
| 525 | |||
| 526 | mutex_lock(&local->key_mtx); | ||
| 527 | sdata->crypto_tx_tailroom_needed_cnt += | ||
| 528 | master->crypto_tx_tailroom_needed_cnt; | ||
| 529 | mutex_unlock(&local->key_mtx); | ||
| 530 | |||
| 525 | break; | 531 | break; |
| 526 | } | 532 | } |
| 527 | case NL80211_IFTYPE_AP: | 533 | case NL80211_IFTYPE_AP: |
| @@ -819,13 +825,15 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata, | |||
| 819 | * (because if we remove a STA after ops->remove_interface() | 825 | * (because if we remove a STA after ops->remove_interface() |
| 820 | * the driver will have removed the vif info already!) | 826 | * the driver will have removed the vif info already!) |
| 821 | * | 827 | * |
| 822 | * This is relevant only in WDS mode, in all other modes we've | 828 | * In WDS mode a station must exist here and be flushed, for |
| 823 | * already removed all stations when disconnecting or similar, | 829 | * AP_VLANs stations may exist since there's nothing else that |
| 824 | * so warn otherwise. | 830 | * would have removed them, but in other modes there shouldn't |
| 831 | * be any stations. | ||
| 825 | */ | 832 | */ |
| 826 | flushed = sta_info_flush(sdata); | 833 | flushed = sta_info_flush(sdata); |
| 827 | WARN_ON_ONCE((sdata->vif.type != NL80211_IFTYPE_WDS && flushed > 0) || | 834 | WARN_ON_ONCE(sdata->vif.type != NL80211_IFTYPE_AP_VLAN && |
| 828 | (sdata->vif.type == NL80211_IFTYPE_WDS && flushed != 1)); | 835 | ((sdata->vif.type != NL80211_IFTYPE_WDS && flushed > 0) || |
| 836 | (sdata->vif.type == NL80211_IFTYPE_WDS && flushed != 1))); | ||
| 829 | 837 | ||
| 830 | /* don't count this interface for promisc/allmulti while it is down */ | 838 | /* don't count this interface for promisc/allmulti while it is down */ |
| 831 | if (sdata->flags & IEEE80211_SDATA_ALLMULTI) | 839 | if (sdata->flags & IEEE80211_SDATA_ALLMULTI) |
