summaryrefslogtreecommitdiffstats
path: root/sys/i386/isa/if_ix.c
diff options
context:
space:
mode:
authorrgrimes <rgrimes@FreeBSD.org>1995-03-02 07:40:27 +0000
committerrgrimes <rgrimes@FreeBSD.org>1995-03-02 07:40:27 +0000
commit5c3ef4de7e1f88e9e088422e9f9445bcdc3ab6ab (patch)
tree37d1d52e87510a1d79a30cb3b4aaec54948aea70 /sys/i386/isa/if_ix.c
parent336da420dbdd3cbe50e1420bd36509852a1b418f (diff)
downloadFreeBSD-src-5c3ef4de7e1f88e9e088422e9f9445bcdc3ab6ab.zip
FreeBSD-src-5c3ef4de7e1f88e9e088422e9f9445bcdc3ab6ab.tar.gz
Remove unused variables, and move some inside of DEBUGDO to quite up
compiler. Be carefull about over usage of volatile, it really killed performance in a few areas and there was a better place to make things volatile in almost all cases. The driver can now receive at full speed without RNR errors.
Diffstat (limited to 'sys/i386/isa/if_ix.c')
-rw-r--r--sys/i386/isa/if_ix.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/sys/i386/isa/if_ix.c b/sys/i386/isa/if_ix.c
index 813ad72..92db779 100644
--- a/sys/i386/isa/if_ix.c
+++ b/sys/i386/isa/if_ix.c
@@ -28,7 +28,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: if_ix.c,v 1.2 1995/02/26 19:40:06 rgrimes Exp $
+ * $Id: if_ix.c,v 1.3 1995/02/26 20:13:14 rgrimes Exp $
*/
#include "ix.h"
@@ -42,6 +42,8 @@
#include <sys/syslog.h>
#include <sys/devconf.h>
+#include <machine/clock.h>
+
#include <net/if.h>
#include <net/if_types.h>
#include <net/if_dl.h>
@@ -808,7 +810,6 @@ ixinit(int unit) {
void
ixinit_rfa(int unit) {
ix_softc_t *sc = &ix_softc[unit];
- scb_t *scb;
rfd_t *rfd;
rbd_t *rbd;
caddr_t rb;
@@ -931,7 +932,6 @@ ixinit_rfa(int unit) {
void
ixinit_tfa(int unit) {
ix_softc_t *sc = &ix_softc[unit];
- scb_t *scb;
cb_transmit_t *cb;
tbd_t *tbd;
caddr_t tb;
@@ -1178,9 +1178,9 @@ ixintr_cx(int unit) {
static inline void
ixintr_cx_free(int unit, cb_t *cb) {
- ix_softc_t *sc = &ix_softc[unit];
DEBUGBEGIN(DEBUGINTR_CX)
+ DEBUGDO(ix_softc_t *sc = &ix_softc[unit];)
DEBUGDO(printf("cb=%x:cb->status=%x:", KVTOBOARD(cb), cb->status);)
DEBUGEND
/*1*/ cb->command = CB_CMD_EL | CB_CMD_NOP;
@@ -1190,7 +1190,6 @@ ixintr_cx_free(int unit, cb_t *cb) {
static inline void
ixintr_fr(int unit) {
ix_softc_t *sc = &ix_softc[unit];
- struct ifnet *ifp = &sc->arpcom.ac_if;
DEBUGBEGIN(DEBUGINTR_FR)
DEBUGDO(printf("fr:");)
@@ -1210,13 +1209,13 @@ ixintr_fr_copy(int unit, rfd_t *rfd) {
caddr_t rb;
struct mbuf *m0, *m;
struct ether_header *eh;
- int i,
- length,
+ int length,
bytesleft;
rbd = (rbd_t *)(sc->maddr + rfd->rbd_offset);
rb = (caddr_t)(sc->maddr + rbd->buffer);
DEBUGBEGIN(DEBUGINTR_FR)
+ DEBUGDO(int i;)
DEBUGDO(printf("rfd=%x:", KVTOBOARD(rfd));)
DEBUGDO(printf("rfd->status=%x:", rfd->status);)
DEBUGDO(printf("rbd->act_count=%x:", rbd->act_count);)
@@ -1448,11 +1447,6 @@ int
ixstop(struct ifnet *ifp) {
int unit = ifp->if_unit;
ix_softc_t *sc = &ix_softc[unit];
- scp_t *scp = (scp_t *)(sc->maddr + SCP_ADDR);
- iscp_t *iscp = (iscp_t *)(sc->maddr + ISCP_ADDR);
- scb_t *scb = (scb_t *)(sc->maddr + SCB_ADDR);
- cb_t *cb;
- tbd_t *tbd;
DEBUGBEGIN(DEBUGSTOP)
DEBUGDO(printf("ixstop:");)
OpenPOWER on IntegriCloud