[Bug 1156] dpdk_flow_ops_fn api returns error for RSS queue action

bugzilla at dpdk.org bugzilla at dpdk.org
Wed Jan 11 15:22:43 CET 2023


https://bugs.dpdk.org/show_bug.cgi?id=1156

            Bug ID: 1156
           Summary: dpdk_flow_ops_fn api returns error for RSS queue
                    action
           Product: DPDK
           Version: 22.03
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: critical
          Priority: Normal
         Component: other
          Assignee: dev at dpdk.org
          Reporter: lthammin at usc.edu
  Target Milestone: ---

Created attachment 238
  --> https://bugs.dpdk.org/attachment.cgi?id=238&action=edit
A temporary patch that solves the issue

Hi,

I would like to enable RSS on a set of queues of port through RTE flow. 

For this I am calling dpdk_flow_ops_fn() by setting
  vnet_flow_t flow;

  flow.queue_index = start_queue_id;
  flow.queue_num = end_queue_id - start_queue_id + 1;

  flow.actions |= VNET_FLOW_ACTION_RSS;

But, dpdk_flow_ops_fn() returns VNET_FLOW_ERROR_NOT_SUPPORTED because it fails
the below condition:
  switch (flow->type)
    {
    case VNET_FLOW_TYPE_ETHERNET:
    case VNET_FLOW_TYPE_IP4:
    case VNET_FLOW_TYPE_IP6:
    case VNET_FLOW_TYPE_IP4_N_TUPLE:
    case VNET_FLOW_TYPE_IP6_N_TUPLE:
    case VNET_FLOW_TYPE_IP4_VXLAN:
    case VNET_FLOW_TYPE_IP4_GTPC:
    case VNET_FLOW_TYPE_IP4_GTPU:
    case VNET_FLOW_TYPE_IP4_L2TPV3OIP:
    case VNET_FLOW_TYPE_IP4_IPSEC_ESP:
    case VNET_FLOW_TYPE_IP4_IPSEC_AH:
    case VNET_FLOW_TYPE_GENERIC:
      if ((rv = dpdk_flow_add (xd, flow, fe)))
        goto done;
      break;
    default:
      rv = VNET_FLOW_ERROR_NOT_SUPPORTED;
      goto done;
    }

It fails because flow->type is not one of above. The flow->type is set only if
a valid RTE flow pattern is required for the flow. For, RTE flows with RSS
Queue action, the pattern is not accepted. So, flow->type in this case should
be invalid (VNET_FLOW_TYPE_UNKNOWN).

If we try to program a RTE flow with some pattern and RSS Queue action, we get
below error.
DBGvpp# sh flow int TenGigabitEthernetb5/0/3
supported flow actions   : count mark buffer-advance redirect-to-node
redirect-to-queue rss drop
last DPDK error type     : 15
last DPDK error message  : RSS Queues not supported when pattern specified
DBGvpp#

dpdk_flow_ops_fn() calls dpdk_flow_add(). Note that, even if dpdk_flow_ops_fn()
is bypassed, dpdk_flow_add() still fails because of the below conditions.
  if (FLOW_IS_ETHERNET_CLASS (f))
    flow_class = FLOW_ETHERNET_CLASS;
  else if (FLOW_IS_IPV4_CLASS (f))
    flow_class = FLOW_IPV4_CLASS;
  else if (FLOW_IS_IPV6_CLASS (f))
    flow_class = FLOW_IPV6_CLASS;
  else
    return VNET_FLOW_ERROR_NOT_SUPPORTED;

I have attached a patch that I have been using temporarily. Please check it out
and provide an official patch.

Thanks,
Nikhil

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mails.dpdk.org/archives/dev/attachments/20230111/41f9c5ed/attachment.htm>


More information about the dev mailing list