From 146c4f79ccc445c12540317abaca82ba8c854a8d Mon Sep 17 00:00:00 2001 From: Stuart Henderson Date: Mon, 11 May 2009 07:56:53 +0000 Subject: Start using VR_RXSTAT_RX_OK instead of VR_RXSTAT_ERR (It exists from the oldest vt86c100a datasheet to the newest vt6105m. FreeBSD indicates that it is more reliable than VR_RXSTAT_ERR for detecting error conditions, that its use results in less incorrectly dropped packets). From chris@. --- sys/dev/pci/if_vr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/dev/pci') diff --git a/sys/dev/pci/if_vr.c b/sys/dev/pci/if_vr.c index dee92d469ca..99915a985db 100644 --- a/sys/dev/pci/if_vr.c +++ b/sys/dev/pci/if_vr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_vr.c,v 1.86 2009/05/10 12:35:46 sthen Exp $ */ +/* $OpenBSD: if_vr.c,v 1.87 2009/05/11 07:56:52 sthen Exp $ */ /* * Copyright (c) 1997, 1998 @@ -807,7 +807,7 @@ vr_rxeof(struct vr_softc *sc) * it should simply get re-used next time this descriptor * comes up in the ring. */ - if (rxstat & VR_RXSTAT_RXERR) { + if ((rxstat & VR_RXSTAT_RX_OK) == 0) { ifp->if_ierrors++; #ifdef VR_DEBUG printf("%s: rx error (%02x):", -- cgit v1.2.3