Error: failed to add vlan 129 to port 2 PMD: rte_eth_dev_vlan_filter(129) returned cannot allocate memory

DPDK test PMD is throwing error when trying to configure 1-4094 vlans to the interfaces (NIC - ConnectX-6 LX, 26.44.1036), everything works upto vlan 128 and start failing afterwards.

Error: failed to add vlan 129 to port 2 PMD: rte_eth_dev_vlan_filter(129) returned cannot allocate memory)

Base OS - Debian 12

DPDK Version - 22.11.8

Question : Is there any limit of 128 vlan filters on this NIC or there is any other settings I may be missing.

# ethtool -k ens3f0np0

Features for ens3f0np0:

rx-checksumming: on

tx-checksumming: on

    tx-checksum-ipv4: off \[fixed\]

    tx-checksum-ip-generic: on

    tx-checksum-ipv6: off \[fixed\]

    tx-checksum-fcoe-crc: off \[fixed\]

    tx-checksum-sctp: off \[fixed\]

scatter-gather: on

    tx-scatter-gather: on

    tx-scatter-gather-fraglist: off \[fixed\]

tcp-segmentation-offload: on

    tx-tcp-segmentation: on

    tx-tcp-ecn-segmentation: off \[fixed\]

    tx-tcp-mangleid-segmentation: off

    tx-tcp6-segmentation: on

generic-segmentation-offload: on

generic-receive-offload: on

large-receive-offload: off

rx-vlan-offload: on

tx-vlan-offload: on

ntuple-filters: off

receive-hashing: on

highdma: on [fixed]

rx-vlan-filter: on

vlan-challenged: off [fixed]

tx-lockless: off [fixed]

netns-local: off [fixed]

tx-gso-robust: off [fixed]

tx-fcoe-segmentation: off [fixed]

tx-gre-segmentation: on

tx-gre-csum-segmentation: on

tx-ipxip4-segmentation: on

tx-ipxip6-segmentation: on

tx-udp_tnl-segmentation: on

tx-udp_tnl-csum-segmentation: on

tx-gso-partial: on

tx-tunnel-remcsum-segmentation: off [fixed]

tx-sctp-segmentation: off [fixed]

tx-esp-segmentation: off [fixed]

tx-udp-segmentation: on

tx-gso-list: off [fixed]

fcoe-mtu: off [fixed]

tx-nocache-copy: off

loopback: off [fixed]

rx-fcs: off

rx-all: on

tx-vlan-stag-hw-insert: on

rx-vlan-stag-hw-parse: off [fixed]

rx-vlan-stag-filter: on [fixed]

l2-fwd-offload: off [fixed]

hw-tc-offload: on

esp-hw-offload: off [fixed]

esp-tx-csum-hw-offload: off [fixed]

rx-udp_tunnel-port-offload: on

tls-hw-tx-offload: off [fixed]

tls-hw-rx-offload: off [fixed]

rx-gro-hw: off [fixed]

tls-hw-record: off [fixed]

rx-gro-list: off

macsec-hw-offload: off [fixed]

rx-udp-gro-forwarding: off

hsr-tag-ins-offload: off [fixed]

hsr-tag-rm-offload: off [fixed]

hsr-fwd-offload: off [fixed]

hsr-dup-offload: off [fixed]

Hello,

The ConnectX6-Lx has a HW/FW limitation of 128 VLANs, hence the error you are receiving.
If more VLANs are needed, you would either need to disable rx-vlan-filter via ethtool (this will allow you to accept more VLANs, but the filtering will need to be done within the DPDK application), or work with rte_flow rules.

If you still encounter any issues, please open a support case and it will be handled based on entitlement.

Thanks,

Jonathan.