From: Johannes Berg <johannes@sipsolutions.net>
To: Tomas Winkler <tomas.winkler@intel.com>
Cc: linville@tuxdriver.com, yi.zhu@intel.com, linux-wireless@vger.kernel.org
Subject: Re: [PATCH 1/1] mac80211: filter probes in ieee80211_rx_mgmt_probe_resp
Date: Sun, 03 Aug 2008 20:14:19 +0200 [thread overview]
Message-ID: <1217787259.4721.18.camel@johannes.berg> (raw)
In-Reply-To: <1217763121-9057-1-git-send-email-tomas.winkler@intel.com>
[-- Attachment #1: Type: text/plain, Size: 1440 bytes --]
On Sun, 2008-08-03 at 14:32 +0300, Tomas Winkler wrote:
> This patch moves filtering statement from ieee80211_rx_bss_info
> which is called for both beacon and probe to ieee80211_rx_mgmt_probe_resp
> and save few cycles in beacon parsing.
Sounds alright to me, but maybe we should then document that
rx_bss_info() only expects data for the right BSSID?
> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
> ---
> net/mac80211/mlme.c | 6 +++---
> 1 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
> index 5358420..0800385 100644
> --- a/net/mac80211/mlme.c
> +++ b/net/mac80211/mlme.c
> @@ -2570,9 +2570,6 @@ static void ieee80211_rx_bss_info(struct net_device *dev,
> DECLARE_MAC_BUF(mac);
> DECLARE_MAC_BUF(mac2);
>
> - if (!beacon && memcmp(mgmt->da, dev->dev_addr, ETH_ALEN))
> - return; /* ignore ProbeResp to foreign address */
> -
> beacon_timestamp = le64_to_cpu(mgmt->u.beacon.timestamp);
>
> if (ieee80211_vif_is_mesh(&sdata->vif) && elems->mesh_id &&
> @@ -2890,6 +2887,9 @@ static void ieee80211_rx_mgmt_probe_resp(struct net_device *dev,
> size_t baselen;
> struct ieee802_11_elems elems;
>
> + if (memcmp(mgmt->da, dev->dev_addr, ETH_ALEN))
> + return; /* ignore ProbeResp to foreign address */
> +
> baselen = (u8 *) mgmt->u.probe_resp.variable - (u8 *) mgmt;
> if (baselen > len)
> return;
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2008-08-03 18:14 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-03 11:32 [PATCH 1/1] mac80211: filter probes in ieee80211_rx_mgmt_probe_resp Tomas Winkler
2008-08-03 18:14 ` Johannes Berg [this message]
2008-08-05 7:14 ` Tomas Winkler
2008-08-05 9:09 ` Johannes Berg
2008-08-05 15:21 ` Tomas Winkler
2008-08-05 15:27 ` Johannes Berg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1217787259.4721.18.camel@johannes.berg \
--to=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=tomas.winkler@intel.com \
--cc=yi.zhu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox