summaryrefslogtreecommitdiff
path: root/sys/dev/bce
diff options
context:
space:
mode:
authorScott Long <scottl@FreeBSD.org>2007-01-20 17:05:12 +0000
committerScott Long <scottl@FreeBSD.org>2007-01-20 17:05:12 +0000
commit089292ab0b9ed6a29a666d73c42fd8f47a9b3847 (patch)
tree1c37ddd4b119029875032cfca2f54ef05ea49d67 /sys/dev/bce
parentc95d2db298766cd678ee66c87f1367ea1d990007 (diff)
Notes
Diffstat (limited to 'sys/dev/bce')
-rw-r--r--sys/dev/bce/if_bce.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/bce/if_bce.c b/sys/dev/bce/if_bce.c
index 9441c5091646..7ada8d0497a6 100644
--- a/sys/dev/bce/if_bce.c
+++ b/sys/dev/bce/if_bce.c
@@ -5231,7 +5231,7 @@ bce_set_rx_mode(struct bce_softc *sc)
{
struct ifnet *ifp;
struct ifmultiaddr *ifma;
- u32 hashes[4] = { 0, 0, 0, 0 };
+ u32 hashes[NUM_MC_HASH_REGISTERS] = { 0, 0, 0, 0, 0, 0, 0, 0 };
u32 rx_mode, sort_mode;
int h, i;
@@ -5279,12 +5279,12 @@ bce_set_rx_mode(struct bce_softc *sc)
if (ifma->ifma_addr->sa_family != AF_LINK)
continue;
h = ether_crc32_le(LLADDR((struct sockaddr_dl *)
- ifma->ifma_addr), ETHER_ADDR_LEN) & 0x7F;
- hashes[(h & 0x60) >> 5] |= 1 << (h & 0x1F);
+ ifma->ifma_addr), ETHER_ADDR_LEN) & 0xFF;
+ hashes[(h & 0xE0) >> 5] |= 1 << (h & 0x1F);
}
IF_ADDR_UNLOCK(ifp);
- for (i = 0; i < 4; i++)
+ for (i = 0; i < NUM_MC_HASH_REGISTERS; i++)
REG_WR(sc, BCE_EMAC_MULTICAST_HASH0 + (i * 4), hashes[i]);
sort_mode |= BCE_RPM_SORT_USER0_MC_HSH_EN;