mac80211: allow self-protected frame tx without sta
authorThomas Pedersen <thomas@cozybit.com>
Fri, 21 Jun 2013 06:50:58 +0000 (23:50 -0700)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 24 Jun 2013 13:59:20 +0000 (15:59 +0200)
Useful for userspace mesh to authenticate and peer without
a station entry, since both steps may fail anyway.

Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/cfg.c

index 93120de..8184d12 100644 (file)
@@ -2827,7 +2827,8 @@ static int ieee80211_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev,
                    !rcu_access_pointer(sdata->bss->beacon))
                        need_offchan = true;
                if (!ieee80211_is_action(mgmt->frame_control) ||
-                   mgmt->u.action.category == WLAN_CATEGORY_PUBLIC)
+                   mgmt->u.action.category == WLAN_CATEGORY_PUBLIC ||
+                   mgmt->u.action.category == WLAN_CATEGORY_SELF_PROTECTED)
                        break;
                rcu_read_lock();
                sta = sta_info_get(sdata, mgmt->da);