Subject: AN985(tlp) & multicast
To: None <tech-net@netbsd.org>
From: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
List: tech-net
Date: 11/17/2001 11:24:23
----Next_Part(Sat_Nov_17_11:24:23_2001_498)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

hi.

cvs log of /sys/dev/ic/tulip.c says:
> revision 1.64
> date: 2000/05/18 03:02:45;  author: thorpej;  state: Exp;  lines:  -3
> Use big-endian CRC on ADMtek multicast hash.

but I couldn't find such specification in their datasheet
and my card with AN985 doesn't work properly without
following patch.
does anyone know why?

my card is:
PCi FNW-2602-T(seems like abocom FE2500)
tlp0 at cardbus1 dev 0 function 0: ADMtek AN985 Ethernet, pass 1.1

---
YAMAMOTO Takashi<yamt@mwd.biglobe.ne.jp>

----Next_Part(Sat_Nov_17_11:24:23_2001_498)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="tulip.c.diff"

Index: tulip.c
===================================================================
RCS file: /cvs/cvsroot/syssrc/sys/dev/ic/tulip.c,v
retrieving revision 1.101
diff -u -p -r1.101 tulip.c
--- tulip.c	2001/11/13 13:14:45	1.101
+++ tulip.c	2001/11/17 01:05:46
@@ -2869,7 +2869,7 @@ tlp_al981_filter_setup(sc)
 			goto allmulti;
 		}
 
-		hash = ether_crc32_be(enm->enm_addrlo, ETHER_ADDR_LEN) >> 26;
+		hash = ether_crc32_le(enm->enm_addrlo, ETHER_ADDR_LEN) & 0x3f;
 		mchash[hash >> 5] |= 1 << (hash & 0x1f);
 		ETHER_NEXT_MULTI(step, enm);
 	}

----Next_Part(Sat_Nov_17_11:24:23_2001_498)----