Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci There is problem with 82576 chips (and probably ...



details:   https://anonhg.NetBSD.org/src/rev/190ab6b9736d
branches:  trunk
changeset: 771686:190ab6b9736d
user:      bouyer <bouyer%NetBSD.org@localhost>
date:      Mon Nov 28 18:21:46 2011 +0000

description:
There is problem with 82576 chips (and probably 82575 too) with hardware vlan
tagging: some packets are sent untagged on the wire.
Follow OpenBSD and disable hardware vlan tagging for these chips
(I couldn't find a hint in other open-source drivers at what could be
wrong ...)

diffstat:

 sys/dev/pci/if_wm.c |  8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diffs (29 lines):

diff -r 4fdbb716f358 -r 190ab6b9736d sys/dev/pci/if_wm.c
--- a/sys/dev/pci/if_wm.c       Mon Nov 28 16:22:14 2011 +0000
+++ b/sys/dev/pci/if_wm.c       Mon Nov 28 18:21:46 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_wm.c,v 1.224 2011/11/19 22:51:23 tls Exp $  */
+/*     $NetBSD: if_wm.c,v 1.225 2011/11/28 18:21:46 bouyer Exp $       */
 
 /*
  * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc.
@@ -76,7 +76,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.224 2011/11/19 22:51:23 tls Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.225 2011/11/28 18:21:46 bouyer Exp $");
 
 #include "rnd.h"
 
@@ -1911,7 +1911,9 @@
        /*
         * If we're a i82543 or greater, we can support VLANs.
         */
-       if (sc->sc_type >= WM_T_82543)
+       if (sc->sc_type == WM_T_82575 || sc->sc_type == WM_T_82576)
+               sc->sc_ethercom.ec_capabilities |= ETHERCAP_VLAN_MTU;
+       else if (sc->sc_type >= WM_T_82543)
                sc->sc_ethercom.ec_capabilities |=
                    ETHERCAP_VLAN_MTU | ETHERCAP_VLAN_HWTAGGING;
 



Home | Main Index | Thread Index | Old Index