From 7d24628c0d1f8d1cbf6fba8808851db320c40b87 Mon Sep 17 00:00:00 2001 From: Johannes Berg Date: Mon, 28 Jan 2008 17:11:43 +0100 Subject: [PATCH] --- yaml --- r: 89831 b: refs/heads/master c: 7d185b8bb17eac9e9d673eb483ded0fbf0b28b97 h: refs/heads/master i: 89829: 387983996e6a9f8ff1998c174e1de7e9ce997cda 89827: 2e162b52298886dbb03b6c6e17e7cd632179c1fd 89823: 8efb6930f95196ec0514fe5e742aa404c51dc931 v: v3 --- [refs] | 2 +- trunk/net/mac80211/tx.c | 21 +++++++++++++++------ 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/[refs] b/[refs] index a325e6c14ea8..91c6dd32d7d7 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: b22052569657925d6de33b19b2c7b7562900defb +refs/heads/master: 7d185b8bb17eac9e9d673eb483ded0fbf0b28b97 diff --git a/trunk/net/mac80211/tx.c b/trunk/net/mac80211/tx.c index 67b509edd431..85d01646abf5 100644 --- a/trunk/net/mac80211/tx.c +++ b/trunk/net/mac80211/tx.c @@ -1409,10 +1409,17 @@ int ieee80211_subif_start_xmit(struct sk_buff *skb, goto fail; } - sta = sta_info_get(local, hdr.addr1); - if (sta) { - sta_flags = sta->flags; - sta_info_put(sta); + /* + * There's no need to try to look up the destination + * if it is a multicast address (which can only happen + * in AP mode) + */ + if (!is_multicast_ether_addr(hdr.addr1)) { + sta = sta_info_get(local, hdr.addr1); + if (sta) { + sta_flags = sta->flags; + sta_info_put(sta); + } } /* receiver is QoS enabled, use a QoS type frame */ @@ -1422,10 +1429,12 @@ int ieee80211_subif_start_xmit(struct sk_buff *skb, } /* - * If port access control is enabled, drop frames to unauthorised - * stations unless they are EAPOL frames from the local station. + * If port access control is enabled, drop unicast frames to + * unauthorised stations unless they are EAPOL frames from the + * local station. */ if (unlikely(sdata->ieee802_1x_pac && + !is_multicast_ether_addr(hdr.addr1) && !(sta_flags & WLAN_STA_AUTHORIZED) && !(ethertype == ETH_P_PAE && compare_ether_addr(dev->dev_addr,