From: Johannes Berg <johannes@sipsolutions.net>
To: Michael Wu <flamingice@sourmilk.net>
Cc: John Linville <linville@tuxdriver.com>, linux-wireless@vger.kernel.org
Subject: Re: [PATCH 3/3] adm8211: Adapt to filter configuration API
Date: Thu, 20 Sep 2007 03:09:20 +0200 [thread overview]
Message-ID: <1190250560.18521.3.camel@johannes.berg> (raw)
In-Reply-To: <200709181742.33948.flamingice@sourmilk.net>
[-- Attachment #1: Type: text/plain, Size: 880 bytes --]
On Tue, 2007-09-18 at 17:42 -0400, Michael Wu wrote:
> + } else if ((*total_flags & FIF_ALLMULTI) || (mc_count > 32)) {
Why the > 32 btw? The other branch below:
> + } else {
> + priv->nar &= ~(ADM8211_NAR_MM | ADM8211_NAR_PR);
> + mc_filter[1] = mc_filter[0] = 0;
> + for (i = 0; i < mc_count; i++) {
> + if (!mclist)
> + break;
> + bit_nr = ether_crc(ETH_ALEN, mclist->dmi_addr) >> 26;
> +
> + bit_nr &= 0x3F;
> + mc_filter[bit_nr >> 5] |= 1 << (bit_nr & 31);
> + mclist = mclist->next;
> + }
looks like it's a simple hashing algorithm to filter for the multicast
address, so any number of addresses should be ok as far as I can tell,
you just see all multicast frames in a given class of the 64 classes you
have. And if many of the >32 addresses hash to the same value, it might
still be advantageous to use the filter.
johannes
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 190 bytes --]
prev parent reply other threads:[~2007-09-20 13:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20070918213833.8850.90828.stgit@magic.sourmilk.net>
2007-09-18 21:42 ` [PATCH 2/3] rtl8187: Adapt to filter configuration API Michael Wu
2007-09-18 21:42 ` [PATCH 3/3] adm8211: " Michael Wu
2007-09-19 17:46 ` Michael Buesch
2007-09-19 21:03 ` Michael Wu
2007-09-20 13:02 ` Michael Buesch
2007-09-20 1:09 ` 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=1190250560.18521.3.camel@johannes.berg \
--to=johannes@sipsolutions.net \
--cc=flamingice@sourmilk.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.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;
as well as URLs for NNTP newsgroup(s).