[processor-sdk/pdk.git] / packages / ti / drv / icss_emac / firmware / icss_dualemac / src / README.txt
1 The ICSS DUAL EMAC firmware consists of the following files:
3 micro_scheduler.asm: contains the initialization routine and the main control loop. Performs following tasks:
4 PRU register initialization
5 Controls that state machine sequence in the main control loop. The following are the 3 states.
6 -> Recieve state (Rcv).
7 -> perform the Ethernet packets recieve functions.
8 -> Transmit state (Xmt).
9 -> perform the Ethernet packets transmit functions.
10 -> Statistics state (STAT).
11 -> perform the statistics calculation for packets drop or recieved.
13 emac_MII_Rcv.asm: contains the packet recieve routines
14 Depending on the current recieve state, call one of the 3 recieve functions.
15 -> FN_RCV_FB.
16 -> Recieves the first 32 bytes at the SOF of the incoming packet.
17 -> FN_RCV_NB.
18 -> Recieves the next 32 bytes blocks inbetween SOF and EOF of the incoming packet.
19 -> FN_RCV_FB.
20 -> Recieves the last 32 bytes at the EOF of the incoming packet.
22 emac_MII_Xmt.asm: contains the packet transmit routines
23 Depending on the current transmit state, call one of the 3 recieve functions.
24 -> FN_XMT_scheduler.
25 -> Check all the transmit queue for packets if any available starts transmitting the packets.
26 -> FN_XMT_queue.
27 -> Transmits the first 32 bytes TX L1 fifo .
28 -> XMT_queue.
29 -> Transmits the next 32 bytes TX L1 fifo.
30 -> FN_XMT_LB.
31 -> Transmits the last 32 bytes TX L1 fifo.
33 emac_statistics.asm: increments the stats count for incoming and outgoing packets
34 Checks if an stats event is pending.
35 -> TX_INCREMENT_STAT_COUNTER
36 -> increments the stats count for TX events.
37 -> RX_INCREMENT_STAT_COUNTER
38 -> increments the stats count for RX events.
40 emac_tts.asm: Perform the TTS (TIME TRIGGERED SENT) function routine
41 Depending on the current TTS states does this following functions.
42 -> FN_TTS_IEP_CFG_PRE_ICSS_REV1/2.
43 -> configures the IEP timer registers.
44 -> FN_TTS_IEP_CFG_CLEAR.
45 -> clear IEP timer configuration.
46 -> FN_TTS_PKT_SIZE_CHECK_ICSS_REV1/2.
47 -> Check if the packet to be sent is within the permissible range.
48 ->FN_TTS_IEP_CMPCFG_ARBITRATION.
49 -> Semphore mechanics for acquiring sharable/common resources.
50 ->FN_TTS_EXIT_IEP_CMPCFG_ARBITRATION.
51 -> Semphore mechanics for releasing sharable/common resources.
54 Prior to reviewing the ICSS DUAL EMAC firmware sources, its essenstial to have a good understanding of the PRU-ICSS subsystem and the PRU Assembly instruction set.
56 In order to gain an understanding of the PRU-ICSSS subsystem please refer to the Technical reference manual for the respective SOC.
58 Link to PRU Assembly document: http://processors.wiki.ti.com/index.php/PRU_Assembly_Instructions
60 Additional information abouthe PRU-ICSS subsystem can be found at: http://processors.wiki.ti.com/index.php/PRU-ICSS