Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 19 Sep 1996 10:18:30 +0900 (JST)
From:      Naoki Hamada <nao@sbl.cl.nec.co.jp>
To:        guido@gvr.win.tue.nl
Cc:        dfr@render.com, Guido.vanRooij@nl.cis.philips.com, freebsd-hackers@freebsd.org
Subject:   Re: new if_vx driver on freefall
Message-ID:  <199609190118.KAA11113@sirius.sbl.cl.nec.co.jp>
In-Reply-To: Guido van Rooij's message of "Tue, 17 Sep 1996 22:45:08 %2B0200 (MET DST)" <199609172045.WAA06494@gvr.win.tue.nl>
References:  <199609172045.WAA06494@gvr.win.tue.nl>

next in thread | previous in thread | raw e-mail | index | archive | help
Hello, guys!

Guido wrote:
>If you happen to have a 3c590, could you undef the BROKEN_AVAIL define and
>see if you card still works after doing a ping -f -s 1000 <some nearby host>
>(as root of course).

I ported Guido's new if_vx to 960801-SNAP and tried it. (A patch
follows my message.) It works very well with and without BROKEN_AVAIL
though my adapter still worked with the old vx driver :-)

Anyway, it is far better than our old and broken vx driver, isn't it?

-nao

--- if_vx.c	Tue Sep 17 16:19:42 1996
+++ /sys/pci/if_vx.c	Thu Sep 19 09:21:11 1996
@@ -232,7 +232,7 @@
     ifp->if_unit = unit;
     ifp->if_name = "vx";
     ifp->if_mtu = ETHERMTU;
-    ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_NOTRAILERS | IFF_MULTICAST;
+    ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
     ifp->if_output = ether_output;
     ifp->if_start = vxstart;
     ifp->if_ioctl = vxioctl;
@@ -242,7 +242,7 @@
     ether_ifattach(ifp);
 
 #if NBPFILTER > 0
-    bpfattach(&ifp->if_bpf, ifp, DLT_EN10MB, sizeof(struct ether_header));
+    bpfattach(ifp, DLT_EN10MB, sizeof(struct ether_header));
 #endif
 
     sc->tx_start_thresh = 20;	/* probably a good starting point. */
@@ -397,7 +397,7 @@
 {
     register struct vx_softc *sc = &vx_softc[ifp->if_unit];
     register struct mbuf *m, *m0;
-    int sh, len, pad;
+    int sh, len, pad, s;
 
     /* Don't transmit if interface is busy or not running */
     if ((sc->arpcom.ac_if.if_flags & (IFF_RUNNING|IFF_OACTIVE)) != IFF_RUNNING)
@@ -449,8 +449,8 @@
 	(len / 4 + sc->tx_start_thresh));
 
 #if NBPFILTER > 0
-    if (ifp->if_bpf) {
-	bpf_mtap(ifp->if_bpf, m0);
+    if (sc->arpcom.ac_if.if_bpf) {
+	bpf_mtap(&sc->arpcom.ac_if, m0);
     }
 #endif
 
@@ -715,8 +715,8 @@
      * Check if there's a BPF listener on this interface.
      * If so, hand off the raw packet to BPF.
      */
-    if (ifp->if_bpf) {
-	bpf_mtap(ifp->if_bpf, m);
+    if (sc->arpcom.ac_if.if_bpf) {
+	bpf_mtap(&sc->arpcom.ac_if, m);
 
 	/*
 	 * Note that the interface cannot be in promiscuous mode if



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