* [PATCH] mv643xx_eth: fix multicast filter programming
@ 2009-01-19 9:58 Lennert Buytenhek
2009-01-20 1:17 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Lennert Buytenhek @ 2009-01-19 9:58 UTC (permalink / raw)
To: David Miller; +Cc: tbm, pacman, netdev, Matt Sealey, Gabriel Paubert
Commit 66e63ffbc04706568d8789cbb00eaa8ddbcae648 ("mv643xx_eth:
implement ->set_rx_mode()") cleaned up mv643xx_eth's multicast filter
programming, but broke it as well.
The non-special multicast filter table (for multicast addresses that
are not of the form 01:00:5e:00:00:xx) consists of 256 hash table
buckets organised as 64 32-bit words, where the 'accept' bits are
in the LSB of each byte, so in bits 24 16 8 0 of each 32-bit word.
The old code got this right, but the referenced commit broke this by
using bits 3 2 1 0 instead. This commit fixes this up.
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
---
drivers/net/mv643xx_eth.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c
index e2aa468..8c6979a 100644
--- a/drivers/net/mv643xx_eth.c
+++ b/drivers/net/mv643xx_eth.c
@@ -1596,7 +1596,7 @@ oom:
entry = addr_crc(a);
}
- table[entry >> 2] |= 1 << (entry & 3);
+ table[entry >> 2] |= 1 << (8 * (entry & 3));
}
for (i = 0; i < 0x100; i += 4) {
--
1.5.6.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] mv643xx_eth: fix multicast filter programming
2009-01-19 9:58 [PATCH] mv643xx_eth: fix multicast filter programming Lennert Buytenhek
@ 2009-01-20 1:17 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2009-01-20 1:17 UTC (permalink / raw)
To: buytenh; +Cc: tbm, pacman, netdev, matt, paubert
From: Lennert Buytenhek <buytenh@wantstofly.org>
Date: Mon, 19 Jan 2009 10:58:13 +0100
> Commit 66e63ffbc04706568d8789cbb00eaa8ddbcae648 ("mv643xx_eth:
> implement ->set_rx_mode()") cleaned up mv643xx_eth's multicast filter
> programming, but broke it as well.
>
> The non-special multicast filter table (for multicast addresses that
> are not of the form 01:00:5e:00:00:xx) consists of 256 hash table
> buckets organised as 64 32-bit words, where the 'accept' bits are
> in the LSB of each byte, so in bits 24 16 8 0 of each 32-bit word.
> The old code got this right, but the referenced commit broke this by
> using bits 3 2 1 0 instead. This commit fixes this up.
>
> Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-01-20 1:17 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-19 9:58 [PATCH] mv643xx_eth: fix multicast filter programming Lennert Buytenhek
2009-01-20 1:17 ` David Miller
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).