Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 09 Jul 2013 15:52:25 +0200
From:      Andreas Longwitz <longwitz@incore.de>
To:        freebsd-net@freebsd.org
Subject:   sis(4) flow control
Message-ID:  <51DC1599.8040805@incore.de>

next in thread | raw e-mail | index | archive | help
Some of my soekris boxes run with sis interfaces. Because I need
ethernet flow control on these boxes I use the following patch (against
8-Stable) for some years:

--- if_sis.c.orig      2013-05-15 20:01:16.000000000 +0200
+++ if_sis.c           2013-06-24 15:58:05.000000000 +0200
@@ -1965,6 +1965,18 @@
        }
 #endif

+       if (sc->sis_type == SIS_TYPE_83815 && sc->sis_srr >= NS_SRR_16A) {
+             if (ifp->if_flags & IFF_LINK0) {
+                /*
+                 * Configure Ethernet flow control for outgoing frames.
+                 * Enable reception of 802.3x multicast pause frames.
+                 */
+                SIS_SETBIT(sc, NS_PCR, NS_PCR_PAUSE );
+             } else {
+                SIS_CLRBIT(sc, NS_PCR, NS_PCR_PAUSE );
+             }
+       }
+
        mii = device_get_softc(sc->sis_miibus);

        /* Set MAC address */

Other network drivers (eg. vr) have this functionality inside, it would
be fine if sis learns flow control too.

---
Andreas Longwitz




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?51DC1599.8040805>