Transmit and retransmit queues, Error conditions that flush the transmit buffer – Altera RapidIO MegaCore Function User Manual

Page 64

Advertising
background image

4–18

Chapter 4: Functional Description

Physical Layer

RapidIO MegaCore Function

August 2014

Altera Corporation

User Guide

The transmit buffer is the main memory in which the packets are stored before they
are transmitted. You can specify a value of 4, 8, 16, or 32 KBytes to configure the total
memory space available for the transmit buffer in non-Arria 10 variations. RapidIO
Arria 10 varations have a total transmit buffer size of 32 KBytes.

The transmit buffer space is partitioned into 64-byte blocks that are allocated from a
free queue and returned to the free queue when no longer needed. The 64-byte blocks
are used on a first-come, first-served basis by the individual transmit and retransmit
queues.

The IP core provides the current number of 64-byte blocks in the free queue in the
atxwlevel

output signal. The transmit buffer also has an output signal, atxovf, which

indicates a transmit buffer overflow condition.

Transmit and Retransmit Queues

To meet the RapidIO specification requirements for packet priority handling and
deadlock avoidance, the Physical layer transmit buffer implements four transmit
queues and four retransmit queues, one for each priority level.

As the Transport layer writes packets to the Physical layer, the Physical layer adds
them to the end of the appropriate priority transmit queue. The transmitter always
transmits the packet at the head of the highest priority non-empty queue. After the
packet is transmitted, the Physical layer moves the packet from the transmit queue to
the corresponding priority retransmit queue.

When a packet-accepted control symbol is received for a non-acknowledged
transmitted packet, the transmit buffer block removes the accepted packet from its
retransmit queue.

If a packet-retry control symbol is received, all of the packets in the retransmit
queues are returned to the head of the corresponding transmit queues. The
transmitter sends a restart-from-retry symbol, and the transmission resumes with
the highest priority packet available, possibly not the same packet that was originally
transmitted and retried. The Transport layer might have written higher priority
packets to the Physical layer since the retried packet was originally transmitted. In
that case, the higher priority packets are chosen automatically to be transmitted before
lower priority packets are retransmitted.

The Physical layer protocol and flow control engine ensures that a maximum of 31
unacknowledged packets are transmitted, and that the ackIDs are used and
acknowledged in ascending order.

Error Conditions that Flush the Transmit Buffer

The following fatal errors cause the transmit buffer to be flushed, and any stored
packets to be lost:

Receive a link-response control symbol with the port_status set to Error.

Receive a link-response control symbol with the port_status set to OK but the
ackid_status

set to an ackID that is not pending (transmitted but not

acknowledged yet).

Transmitter times out while waiting for link-response.

Receiver times out while waiting for link-request.

Advertising