*** if_lnc.c.orig Mon Aug 9 16:23:27 1999 --- if_lnc.c Tue Aug 10 12:10:07 1999 *************** *** 1504,1516 **** write_csr(sc, CSR3, 0); /* Let's see if it starts */ write_csr(sc, CSR0, INIT); for (i = 0; i < 1000; i++) if (read_csr(sc, CSR0) & IDON) break; - /* * Now that the initialisation is complete there's no reason to * access anything except CSR0, so we leave RAP pointing there --- 1504,1528 ---- write_csr(sc, CSR3, 0); + /* + * If we have a Am79C97x series card, we set the NOUFLO bit + * (bit 11) in BCR18 to avoid underflow errors. + * The #define's really should go to ic/Am79C972.h + */ + #define BCR18 18 + #define NOUFLO 0x0800 + if (sc->nic.ic > PCnet_FAST) { + u_short oval; + oval = read_bcr (sc, BCR18); + write_bcr (sc, BCR18, oval|NOUFLO); + } + /* Let's see if it starts */ write_csr(sc, CSR0, INIT); for (i = 0; i < 1000; i++) if (read_csr(sc, CSR0) & IDON) break; /* * Now that the initialisation is complete there's no reason to * access anything except CSR0, so we leave RAP pointing there