From ba1e69b42df4fac5180fbdcd0306b92f28a1cc36 Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Thu, 16 Feb 2006 20:54:36 +0000 Subject: Do not bother enabling HW TX checksum offload since the code to support this feature was removed awhile ago. --- sys/dev/pci/if_nge.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) (limited to 'sys/dev/pci') diff --git a/sys/dev/pci/if_nge.c b/sys/dev/pci/if_nge.c index a5b59a27f5d..0ab5f873b8a 100644 --- a/sys/dev/pci/if_nge.c +++ b/sys/dev/pci/if_nge.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_nge.c,v 1.48 2005/11/23 11:30:14 mickey Exp $ */ +/* $OpenBSD: if_nge.c,v 1.49 2006/02/16 20:54:35 brad Exp $ */ /* * Copyright (c) 2001 Wind River Systems * Copyright (c) 1997, 1998, 1999, 2000, 2001 @@ -892,6 +892,10 @@ nge_attach(parent, self, aux) ifp->if_capabilities = IFCAP_VLAN_MTU; +#ifdef NGE_VLAN + ifp->if_capabilities |= IFCAP_VLAN_HWTAGGING; +#endif + /* * Do MII setup. */ @@ -1768,20 +1772,18 @@ nge_init(xsc) NGE_SETBIT(sc, NGE_RXFILT_CTL, NGE_RXFILTCTL_PERFECT); /* If we want promiscuous mode, set the allframes bit. */ - if (ifp->if_flags & IFF_PROMISC) { + if (ifp->if_flags & IFF_PROMISC) NGE_SETBIT(sc, NGE_RXFILT_CTL, NGE_RXFILTCTL_ALLPHYS); - } else { + else NGE_CLRBIT(sc, NGE_RXFILT_CTL, NGE_RXFILTCTL_ALLPHYS); - } /* * Set the capture broadcast bit to capture broadcast frames. */ - if (ifp->if_flags & IFF_BROADCAST) { + if (ifp->if_flags & IFF_BROADCAST) NGE_SETBIT(sc, NGE_RXFILT_CTL, NGE_RXFILTCTL_BROAD); - } else { + else NGE_CLRBIT(sc, NGE_RXFILT_CTL, NGE_RXFILTCTL_BROAD); - } /* * Load the multicast filter. @@ -1811,11 +1813,6 @@ nge_init(xsc) /* Set TX configuration */ CSR_WRITE_4(sc, NGE_TX_CFG, NGE_TXCFG); - /* - * Enable TX IPv4 checksumming on a per-packet basis. - */ - CSR_WRITE_4(sc, NGE_VLAN_IP_TXCTL, NGE_VIPTXCTL_CSUM_PER_PKT); - #if NVLAN > 0 /* * If VLAN support is enabled, tell the chip to insert -- cgit v1.2.3