summaryrefslogtreecommitdiff
path: root/sys/dev/pci/if_em.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2008-06-15 16:37:01 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2008-06-15 16:37:01 +0000
commit0f04cb288d7e071fbcdbd4d5e0616811498123b2 (patch)
tree6269241aab09befe6a8a4f55f18e18444baee786 /sys/dev/pci/if_em.c
parent0f7433d8b98c92f577dd51724a870a855803fcf9 (diff)
Don't see rx_abs_int_delay if rx_int_delay is not set. Setting
rx_abs_int_delay to be non-zero when rx_int_delay is zero appears to trigger a bug elsewhere in the kernel for certain em revisions. Based on a diff from beck@. OK beck@ marco@ henning@ brad@
Diffstat (limited to 'sys/dev/pci/if_em.c')
-rw-r--r--sys/dev/pci/if_em.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/pci/if_em.c b/sys/dev/pci/if_em.c
index 3a5d117c5b4..1568a17b56a 100644
--- a/sys/dev/pci/if_em.c
+++ b/sys/dev/pci/if_em.c
@@ -31,7 +31,7 @@ POSSIBILITY OF SUCH DAMAGE.
***************************************************************************/
-/* $OpenBSD: if_em.c,v 1.184 2008/06/08 16:20:27 reyk Exp $ */
+/* $OpenBSD: if_em.c,v 1.185 2008/06/15 16:37:00 millert Exp $ */
/* $FreeBSD: if_em.c,v 1.46 2004/09/29 18:28:28 mlaier Exp $ */
#include <dev/pci/if_em.h>
@@ -2432,7 +2432,8 @@ em_initialize_receive_unit(struct em_softc *sc)
sc->rx_int_delay | E1000_RDT_FPDB);
if (sc->hw.mac_type >= em_82540) {
- E1000_WRITE_REG(&sc->hw, RADV, sc->rx_abs_int_delay);
+ if (sc->rx_int_delay)
+ E1000_WRITE_REG(&sc->hw, RADV, sc->rx_abs_int_delay);
/* Set the interrupt throttling rate. Value is calculated
* as DEFAULT_ITR = 1/(MAX_INTS_PER_SEC * 256ns) */