Checksum Offload

MLNX_EN supports the following Receive IP/L4 Checksum Offload modes:

  • CHECKSUM_UNNECESSARY: By setting this mode the driver indicates to the Linux Networking Stack that the hardware successfully validated the IP and L4 checksum so the Linux Networking Stack does not need to deal with IP/L4 Checksum validation.
    Checksum Unnecessary is passed to the OS when all of the following are true:

    • Ethtool -k <DEV> shows rx-checksumming: on

    • Received TCP/UDP packet and both IP checksum and L4 protocol checksum are correct.

  • CHECKSUM_COMPLETE: When the checksum validation cannot be done or fails, the driver still reports to the OS the calculated by hardware checksum value. This allows accelerating checksum validation in Linux Networking Stack, since it does not have to calculate the whole checksum including payload by itself.
    Checksum Complete is passed to OS when all of the following are true:

    • Ethtool -k <DEV> shows rx-checksumming: on

    • Using ConnectX®-3, firmware version 2.31.7000 and up

    • Received IpV4/IpV6 non-TCP/UDP packet

Warning

The ingress parser of the ConnectX®-3-Pro card comes by default without checksum
offload support for non-TCP/UDP packets.
To change that, please set the value of the module parameter ingress_parser_mode
in mlx4_core to 1.
In this mode, IPv4/IPv6 non-TCP/UDP packets will be passed up to the protocol stack with CHECKSUM_COMPLETE tag.
In this mode of the ingress parser, the following features are unavailable:

  • NVGRE stateless offloads

  • VXLAN stateless offloads

  • RoCE v2 (RoCE over UDP)

Change the default behavior only if non tcp/udp is very common.

  • CHECKSUM_NONE: By setting this mode the driver indicates to the Linux Networking Stack that the hardware failed to validate the IP or L4 checksum so the Linux Networking Stack must calculate and validate the IP/L4 Checksum.
    Checksum None is passed to OS for all other cases.

© Copyright 2023, NVIDIA. Last updated on May 23, 2023.