Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-5]: src/sys/dev/ic Pull up revision 1.28 (requested by tsutsui):
details: https://anonhg.NetBSD.org/src/rev/4ad646379f5b
branches: netbsd-1-5
changeset: 490849:4ad646379f5b
user: he <he%NetBSD.org@localhost>
date: Tue Mar 13 20:43:55 2001 +0000
description:
Pull up revision 1.28 (requested by tsutsui):
Handle allmulti case correctly as a NetBSD network driver;
if we are requested range of multicast address or too many
multicast address, program multicast filter to receive all
multicast address. And set/clear IFF_ALLMULTI flag properly.
diffstat:
sys/dev/ic/rtl81x9.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diffs (38 lines):
diff -r beb82f87df96 -r 4ad646379f5b sys/dev/ic/rtl81x9.c
--- a/sys/dev/ic/rtl81x9.c Tue Mar 13 20:33:15 2001 +0000
+++ b/sys/dev/ic/rtl81x9.c Tue Mar 13 20:43:55 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rtl81x9.c,v 1.11.4.3 2001/02/26 21:19:32 he Exp $ */
+/* $NetBSD: rtl81x9.c,v 1.11.4.4 2001/03/13 20:43:55 he Exp $ */
/*
* Copyright (c) 1997, 1998
@@ -564,7 +564,9 @@
rxfilt = CSR_READ_4(sc, RTK_RXCFG);
- if (ifp->if_flags & IFF_ALLMULTI || ifp->if_flags & IFF_PROMISC) {
+ if (ifp->if_flags & IFF_PROMISC) {
+allmulti:
+ ifp->if_flags |= IFF_ALLMULTI;
rxfilt |= RTK_RXCFG_RX_MULTI;
CSR_WRITE_4(sc, RTK_RXCFG, rxfilt);
CSR_WRITE_4(sc, RTK_MAR0, 0xFFFFFFFF);
@@ -581,7 +583,7 @@
while (enm != NULL) {
if (memcmp(enm->enm_addrlo, enm->enm_addrhi,
ETHER_ADDR_LEN) != 0)
- continue;
+ goto allmulti;
h = rtk_calchash(enm->enm_addrlo);
if (h < 32)
@@ -592,6 +594,8 @@
ETHER_NEXT_MULTI(step, enm);
}
+ ifp->if_flags &= ~IFF_ALLMULTI;
+
if (mcnt)
rxfilt |= RTK_RXCFG_RX_MULTI;
else
Home |
Main Index |
Thread Index |
Old Index