Figure 5.1 shows the key elements of the Link layer and outlines the major focal points of this section.
When requested by the Transport layer to transmit a frame, the Link layer provides the following services:
1. Negotiates with its peer Link layer to transmit a frame; resolves arbitration conflicts if both host and device request transmission
2. Inserts a frame envelope around Transport layer data (i.e., SOF, CRC, EOF, etc.) 3. Receives data in the form of DWORDs from the Transport layer 4. Calculates CRC on Transport layer data 5. Transmits frames 6. Provides frame flow control in response to requests from the FIFO or the peer Link layer 7. Receives frame receipt acknowledgment from the peer Link layer 8. Reports good transmission or Link/Physical layer errors to the Transport layer 9. Performs 8b10b encoding 10. Scrambles (transforms) control and data DWORDs in such a way as to distribute the potential
EMI emissions over a broader range
When data is received from the Physical layer, the Link layer provides the following services:
1. Acknowledges to the peer Link layer readiness to receive a frame 2. Receives data in the form of encoded characters from the Physical layer 3. Decodes the encoded 8b10b character stream into aligned DWORDs of data 4. Removes the envelope around frames (i.e., SOF, CRC, EOF) 5. Calculates CRC on the received DWORDs 6. Provides frame flow control in response to requests from the FIFO or the peer Link layer 7. Compares the calculated CRC to the received CRC 8. Reports good reception or Link/Physical layer errors to the Transport layer and the peer Link
layer 9. Descrambles (untransforms) the control and data DWORDs received from a peer Link layer
The information on the serial line is a sequence of 8b10b encoded characters. The smallest unit of communication is known as a DWORD (see Chapter 2, Table 2.20-SATA Character Format). The contents of each DWORD provide link level control information to transfer information between hosts and devices.