Module Name: src Committed By: martin Date: Thu Oct 17 19:02:55 UTC 2019
Modified Files: src/sys/dev/pci [netbsd-9]: if_et.c Log Message: Pull up following revision(s) (requested by msaitoh in ticket #346): sys/dev/pci/if_et.c: revision 1.27 Fix a bug that multicast address filter doesn't work correctly. XXX pullup-[789]. To generate a diff of this commit: cvs rdiff -u -r1.24.2.1 -r1.24.2.2 src/sys/dev/pci/if_et.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/pci/if_et.c diff -u src/sys/dev/pci/if_et.c:1.24.2.1 src/sys/dev/pci/if_et.c:1.24.2.2 --- src/sys/dev/pci/if_et.c:1.24.2.1 Fri Aug 9 16:03:13 2019 +++ src/sys/dev/pci/if_et.c Thu Oct 17 19:02:54 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: if_et.c,v 1.24.2.1 2019/08/09 16:03:13 martin Exp $ */ +/* $NetBSD: if_et.c,v 1.24.2.2 2019/10/17 19:02:54 martin Exp $ */ /* $OpenBSD: if_et.c,v 1.12 2008/07/11 09:29:02 kevlo $ */ /* * Copyright (c) 2007 The DragonFly Project. All rights reserved. @@ -37,7 +37,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: if_et.c,v 1.24.2.1 2019/08/09 16:03:13 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_et.c,v 1.24.2.2 2019/10/17 19:02:54 martin Exp $"); #include "opt_inet.h" #include "vlan.h" @@ -1304,7 +1304,6 @@ et_setmulti(struct et_softc *sc) uint32_t rxmac_ctrl, pktfilt; struct ether_multi *enm; struct ether_multistep step; - uint8_t addr[ETHER_ADDR_LEN]; int i, count; pktfilt = CSR_READ_4(sc, ET_PKTFILT); @@ -1316,19 +1315,13 @@ et_setmulti(struct et_softc *sc) goto back; } - bcopy(etherbroadcastaddr, addr, ETHER_ADDR_LEN); - count = 0; ETHER_LOCK(ec); ETHER_FIRST_MULTI(step, ec, enm); while (enm != NULL) { uint32_t *hp, h; - for (i = 0; i < ETHER_ADDR_LEN; i++) { - addr[i] &= enm->enm_addrlo[i]; - } - - h = ether_crc32_be(addr, ETHER_ADDR_LEN); + h = ether_crc32_be(enm->enm_addrlo, ETHER_ADDR_LEN); h = (h & 0x3f800000) >> 23; hp = &hash[0];