Issue with DOCA Flow ETH RXQ Queue ID and `doca_flow_pipe_add_entry()`

Hi There,

I encountered an issue related to the DOCA ETH RXQ while using the doca_flow_pipe_add_entry function. The DOCA version is 2.9.1 LTS

Issue Description

According to the Working with DOCA Flow to route incoming packets to a DOCA ETH RXQ, the following steps should be performed:

  1. Create and start DOCA Flow on the appropriate port.
  2. Create pipes to route packets.
  3. Obtain the queue ID inside DOCA ETH RXQ using:
    doca_eth_rxq_get_flow_queue_id()  
    
  4. Add an entry to a pipe that routes packets into the RX queue, using the obtained queue ID.

I successfully created a doca_eth_rxq, and the printed queue_id was 64536. However, when I used this queue ID as the pipe_queue parameter in the doca_flow_pipe_add_entry() function:

doca_error_t doca_flow_pipe_add_entry(
    uint16_t pipe_queue,
    struct doca_flow_pipe *pipe,
    const struct doca_flow_match *match,
    const struct doca_flow_actions *actions,
    const struct doca_flow_monitor *monitor,
    const struct doca_flow_fwd *fwd,
    uint32_t flags,
    void *usr_ctx,
    struct doca_flow_pipe_entry **entry
);

I encountered the following error messages:

[03:31:41:938130][2201062][DOCA][ERR][hws_mempool.c:272][hws_mempool_alloc] Failed to allocate memory, data/cache is NULL in pool 0x17abad200
[03:31:41:938148][2201062][DOCA][ERR][dpdk_pipe_legacy.c:214][dpdk_pipe_entry_alloc] alloc new pipe entry from memory pool fail, pipe:ROOT_PIPE, queue:64536
[03:31:41:938164][2201062][DOCA][ERR][dpdk_pipe_legacy.c:439][add_entry] failed to create entry - entry pool depleted on pipe ROOT_PIPE
[03:31:41:938178][2201062][DOCA][ERR][engine_pipe.c:1260][engine_pipe_entry_add] failed adding entry - driver entry creation failed
[03:31:41:938193][2201062][DOCA][ERR][doca_flow.c:1049][doca_flow_pipe_add_entry] pipe entry add failed, rc = -12

I attempted to increase the number of queues using:

doca_flow_cfg_set_pipe_queues()  

However, the system limits the maximum number of queues to 16, which corresponds to the number of CPU cores.

Thanks.

The pipe queue in DOCA Flow is different from RSS queue. DOCA Flow queue is queue of pipe entries. Using multiple queues and binding queues to CPU cores lets CPU cores update pipe entries concurrently, which is useful then the application need to update pipe entry at a high speed.
The queue id got by doca_eth_rxq_get_flow_queue_id() should be used with doca_flow_fwd when configuring pipe or pipe queue, like:

	struct doca_flow_fwd all_fwd = {.type = DOCA_FLOW_FWD_RSS,
					.rss_queues = rxq_flow_queue_ids,
					.num_of_queues = nb_queues,
					.rss_outer_flags = DOCA_FLOW_RSS_IPV4 | DOCA_FLOW_RSS_UDP};