Definition:
The GbE Link State Machine (LSM) inside the RX side of the PCS monitors the incoming data for COMMA characters. The first time it detects a COMMA character , it assigns an "even" index to the cycle, and expects any new COMMA characters to also appear on an even boundary. If another COMMA appears on an odd index, then this is considered an error and too many COMMAS in the odd index can cause the LSM to lose sync and start looking for new COMMAS again. This behavior conforms to the IEEE 802.3-2002 GbE Link State Machine specification.
As a result, The PCS LSM status output signal (ffs_ls_sync_status_ch[3:0] or lsm_status_[0-3], depending on FPGA device) goes low when the LSM loses sync, and goes back high when the LSM acquires sync again.
The two example below illustrate the difference between a valid and an invalid even boundary COMMA occurence (C=comma, D=data):
1. VALID COMMA SEQUENCE:
| INDEX | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| CHARACTER | C | D | C | D | C | D | D | D | D | D | C | D |
2. INVALID COMMA SEQUENCE:
| INDEX | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| CHARACTER | C | D | C | D | C | D | D | D | D | C | D | C |
In example 2, The COMMAs on INDEX 9 and 11 are invalid since they do not fall on an even boundary.
Note that you do not need to create your own COMMA indexing transmission sequence if you use the SGMII and Gb Ethernet PCS IP Core (IPUG60) for the LatticeECP2M and LatticeECP3 devices. The IP automatically properly aligns COMMAs during the Idle phase of Ethernet frames transmission.