Texas Instruments TNETE110A Network Card User Manual


 
Interrupt Type Codes
4-9
Interrupt Handling
4.4.6 Tx EOC Interrupt. Int_type = 101b
A Tx EOC interrupt occurs when ThunderLAN encounters a forward pointer
of 0 in the Tx list structure or when the Ld_Thr bit is loaded with 0. In this routine
the driver:
Gets the pointer to the Tx buffer queue
Checks the list CSTAT to see if a frame has been transmitted
If no, acknowledges the interrupt and exits
If yes, writes a 0 to CSTAT to make the list invalid
4.4.7 Network Status Interrupt. Int_type = 110b and Int_Vec = 00h
A network status interrupt occurs when a PHY status change has been de-
tected and ThunderLAN has seen an interrupt on the MDIO line. This interrupt
type occurs only if a physical interface (PHY) with enhanced media indepen-
dent interface (MII) support is used.
Some other causes of a status interrupt occur when the Tx and Rx channels
are stopped using a STOP command. The following shows the flow for a status
interrupt routine:
Reads the NetSts
register
Clears the NetSts register. NetSts
can be easily cleared by writing what
has been read back into it.
Reads the NetMask
register
Uses NetMask to ignore the NetSts bits, which are disabled
Evaluates the following conditions:
If the MIRQ bit is set, there was an MII interrupt from the PHY. For
voice grade (VG) operation, this is an indication that the PHY needs to
retrain.
If the HBEAT bit is set, a heartbeat error was detected.
If the TXSTOP bit is set, a Tx STOP command was given and the Tx
channel is stopped.
If the RXSTOP bit is set, an Rx STOP command was given and the Rx
channel is stopped.
Acknowledges interrupts and exits