Compaq AA-RNG2A-TE manual Implementing the elerror Routine, Queuing Other Transmits

Models: AA-RNG2A-TE

1 159
Download 159 pages 42.56 Kb
Page 150
Image 150

2

Updates the softc data structure with the amount of space that is available in the transmit FIFO.

13.3.5 Queuing Other Transmits

The following code shows how the el_tint( ) routine clears the output active flag to permit other transmits to be queued to the device:

ifp->if_flags &= ~IFF_OACTIVE;

}

13.4 Implementing the el_error Routine

The if_el driver’s el_error( ) routine implements the interface adapter error routine, as follows:

static void el_error(struct el_softc *sc, struct ifnet *ifp)

{

int i;

WRITE_CMD(sc, CMD_WINDOW4);

i = READ_FDP(sc); 1

printf("el%d: Adapter Failure - %04X\n", ifp->if_unit, i); el_reset_locked(sc, ifp, ifp->if_unit); 2

}

1

2

Reads the FIFO diagnostic port register.

Resets the adapter to clear the failure condition.

13–12Implementing the Interrupt Section

Page 150
Image 150
Compaq AA-RNG2A-TE manual Implementing the elerror Routine, Queuing Other Transmits