Low Latency 40G Ethernet Intel® FPGA IP User Guide: Agilex™ 5 FPGAs and SoCs

ID 813652
Date 7/22/2024
Public
Document Table of Contents

4.6.2. Length Checking

The MAC TX/RX function checks the frame and payload lengths of basic, VLAN tagged, and stacked VLAN tagged frames.

The frame length must be at least 64 (0x40) bytes and not exceed the MAX_TX_SIZE_CONFIG on MAC TX or MAX_RX_SIZE_CONFIG on MAC RX. MAC TX/RX does not drop frames or packet data even if an error has been detected. The MAC TX/RX keeps track of the actual payload length as it monitoring a TX/RX frame, and it checks the actual payload length against the length/type or client length/type field.

As the existence of padding when frame length is less than 64 bytes and over-padding when frame length is more than 64 bytes, the MAC TX/RX does not try to match the actual payload length value with the frame length/type field value. The MAC TX/RX marks "payload length error" only when the actual payload length is smaller than the frame length/type or client length/type field.

The MAC TX/RX checks for the following types of length error:

  • Undersized frame error: If actual packet frame byte count is less than 64 bytes, the packet are marked as "undersized frame".
  • Oversized frame error: If actual packet frame byte count is more than MAX_TX/RX_SIZE_CONFIG, the packet is marked as "oversized frame". This applies to all packets including basic/VLAN/Stacked VLAN or other types of packets.
  • Payload length error:
    • Basic Ethernet packet:
      • If the length/type field is less than or equal to 1500 bytes, and the actual payload length is smaller than length/type field, the packet is marked as "payload length error".
      • If the length/type field is more than 1500 bytes, payload length are not checked. "Payload length error" are not marked to this kind of packets.
    • VLAN tagged frames: If the "Vlan dectection" feature is disabled, "payload length error" does not apply to Vlan/Stacked Vlan packets. Otherwise, following rules applies to decide if packet has "payload length error".
      • If the length/type field is less than or equal to 1500 bytes, and the actual payload length is smaller than length/type field, the packet are marked as "payload length error".
      • If the length/type field is more than 1500 bytes, payload length are not checked. "Payload length error" are not marked to this kind of packets.
    • Control packet (0x8808): The "payload length error" does not apply to this type of packet.