diff options
author | Brad Smith <brad@cvs.openbsd.org> | 2004-09-28 00:21:24 +0000 |
---|---|---|
committer | Brad Smith <brad@cvs.openbsd.org> | 2004-09-28 00:21:24 +0000 |
commit | cf535cb2a696315685dd770ec7ee82b244de6159 (patch) | |
tree | 4c54a520bef97d844779f564490c586e2a782257 /sys/arch/sparc/dev/hme.c | |
parent | 80dce2e7d18adec0e477b0e67c6afec515c76e53 (diff) |
- Use ETHER_MAX_LEN + ETHER_VLAN_ENCAP_LEN instead of HME_MTU
- Use ETHER_CRC_POLY_LE instead of MC_POLY_LE from hmereg.h
Diffstat (limited to 'sys/arch/sparc/dev/hme.c')
-rw-r--r-- | sys/arch/sparc/dev/hme.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sys/arch/sparc/dev/hme.c b/sys/arch/sparc/dev/hme.c index d020ff8290b..b361dbc35a8 100644 --- a/sys/arch/sparc/dev/hme.c +++ b/sys/arch/sparc/dev/hme.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hme.c,v 1.43 2004/08/08 19:01:20 brad Exp $ */ +/* $OpenBSD: hme.c,v 1.44 2004/09/28 00:21:23 brad Exp $ */ /* * Copyright (c) 1998 Jason L. Wright (jason@thought.net) @@ -69,10 +69,6 @@ #include <net/bpfdesc.h> #endif -#if NVLAN > 0 -#include <net/if_vlan_var.h> -#endif - #include <machine/autoconf.h> #include <sparc/cpu.h> #include <sparc/sparc/cpuvar.h> @@ -249,7 +245,7 @@ hmeattach(parent, self, aux) ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_NOTRAILERS | IFF_MULTICAST; sc->sc_if_flags = ifp->if_flags; - ifp->if_capabilities |= IFCAP_VLAN_MTU; + ifp->if_capabilities = IFCAP_VLAN_MTU; IFQ_SET_MAXLEN(&ifp->if_snd, HME_TX_RING_SIZE); IFQ_SET_READY(&ifp->if_snd); @@ -565,7 +561,7 @@ hmeinit(sc) sc->sc_arpcom.ac_enaddr[3]; cr->mac_addr2 = (sc->sc_arpcom.ac_enaddr[4] << 8) | sc->sc_arpcom.ac_enaddr[5]; - cr->tx_pkt_max = cr->rx_pkt_max = HME_MTU; + cr->tx_pkt_max = cr->rx_pkt_max = ETHER_MAX_LEN + ETHER_VLAN_ENCAP_LEN; cr->jsize = HME_DEFAULT_JSIZE; cr->ipkt_gap1 = HME_DEFAULT_IPKT_GAP1; @@ -962,7 +958,7 @@ hme_mcreset(sc) for (j = 0; j < 8; j++) { if ((crc & 1) ^ (octet & 1)) { crc >>= 1; - crc ^= MC_POLY_LE; + crc ^= ETHER_CRC_POLY_LE; } else crc >>= 1; |