Linux wireless drivers development
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Andrey Yurovsky <andrey@cozybit.com>
Cc: linux-wireless@vger.kernel.org
Subject: Re: [PATCH] mac80211: disable BSSID filtering for mesh interfaces
Date: Fri, 31 Oct 2008 22:54:30 +0100	[thread overview]
Message-ID: <1225490070.3550.2.camel@johannes.berg> (raw)
In-Reply-To: <490b7d94.18038e0a.6666.ffff8d72@mx.google.com> (sfid-20081031_225017_677715_6F575E2C)

[-- Attachment #1: Type: text/plain, Size: 1801 bytes --]

On Fri, 2008-10-31 at 14:50 -0700, Andrey Yurovsky wrote:
> Mesh interfaces are currently opened with the FIF_ALLMULTI rx filter flag set,
> however there is no BSSID in mesh so BSSID filtering should be disabled by
> setting the FIF_OTHER_BSS flag as well.  Also explicitly call 
> ieee80211_configure_filter for mesh.
> 
> Signed-off-by: Andrey Yurovsky <andrey@cozybit.com>
> Signed-off-by: Javier Cardona <javier@cozbit.com>

Acked-by: Johannes Berg <johannes@sipsolutions.net>

> diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c
> index cde1452..6c3901a 100644
> --- a/net/mac80211/iface.c
> +++ b/net/mac80211/iface.c
> @@ -229,8 +229,14 @@ static int ieee80211_open(struct net_device *dev)
>  		if (res)
>  			goto err_stop;
>  
> -		if (ieee80211_vif_is_mesh(&sdata->vif))
> +		if (ieee80211_vif_is_mesh(&sdata->vif)) {
> +			local->fif_other_bss++;
> +			netif_addr_lock_bh(local->mdev);
> +			ieee80211_configure_filter(local);
> +			netif_addr_unlock_bh(local->mdev);
> +
>  			ieee80211_start_mesh(sdata);
> +		}
>  		changed |= ieee80211_reset_erp_info(sdata);
>  		ieee80211_bss_info_change_notify(sdata, changed);
>  		ieee80211_enable_keys(sdata);
> @@ -456,8 +462,15 @@ static int ieee80211_stop(struct net_device *dev)
>  		/* fall through */
>  	case NL80211_IFTYPE_MESH_POINT:
>  		if (ieee80211_vif_is_mesh(&sdata->vif)) {
> -			/* allmulti is always set on mesh ifaces */
> +			/* other_bss and allmulti are always set on mesh
> +			 * ifaces */
> +			local->fif_other_bss--;
>  			atomic_dec(&local->iff_allmultis);
> +
> +			netif_addr_lock_bh(local->mdev);
> +			ieee80211_configure_filter(local);
> +			netif_addr_unlock_bh(local->mdev);
> +
>  			ieee80211_stop_mesh(sdata);
>  		}
>  		/* fall through */
> 
> 
> 

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

      reply	other threads:[~2008-10-31 21:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-31 21:50 [PATCH] mac80211: disable BSSID filtering for mesh interfaces Andrey Yurovsky
2008-10-31 21:54 ` Johannes Berg [this message]

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=1225490070.3550.2.camel@johannes.berg \
    --to=johannes@sipsolutions.net \
    --cc=andrey@cozybit.com \
    --cc=linux-wireless@vger.kernel.org \
    /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