diff options
Diffstat (limited to 'sys/dev/bge/if_bge.c')
-rw-r--r-- | sys/dev/bge/if_bge.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/dev/bge/if_bge.c b/sys/dev/bge/if_bge.c index 3a2321a..0b8328c 100644 --- a/sys/dev/bge/if_bge.c +++ b/sys/dev/bge/if_bge.c @@ -209,7 +209,7 @@ static void bge_ifmedia_sts (struct ifnet *, struct ifmediareq *); static u_int8_t bge_eeprom_getbyte (struct bge_softc *, int, u_int8_t *); static int bge_read_eeprom (struct bge_softc *, caddr_t, int, int); -static u_int32_t bge_crc (caddr_t); +static u_int32_t bge_mchash (caddr_t); static void bge_setmulti (struct bge_softc *); static void bge_handle_events (struct bge_softc *); @@ -1134,10 +1134,12 @@ bge_init_tx_ring(sc) #define BGE_POLY 0xEDB88320 static u_int32_t -bge_crc(addr) +bge_mchash(addr) caddr_t addr; { - u_int32_t idx, bit, data, crc; + u_int32_t crc; + int idx, bit; + u_int8_t data; /* Compute CRC for the address value. */ crc = 0xFFFFFFFF; /* initial value */ @@ -1177,7 +1179,7 @@ bge_setmulti(sc) TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK) continue; - h = bge_crc(LLADDR((struct sockaddr_dl *)ifma->ifma_addr)); + h = bge_mchash(LLADDR((struct sockaddr_dl *)ifma->ifma_addr)); hashes[(h & 0x60) >> 5] |= 1 << (h & 0x1F); } |