Hi Team,

Is there any possible way to create multiple RSS flows to distribute packets to set of queues when a particular Ip pattern matches.
For e.g.,
I have 40 RX queues setup,
Flow 1: Match a particular IP pattern and distribute it to specified RX queues set (0 - 29)
Flow 2: Match a particular IP pattern and distribute it to specified RX queues set (30 - 39)

Is the below code snippet possible? Also is it possible to use symmetric toeplitz  hash and ETH_RSS_L3_SRC_ONLY | ETH_RSS_L3_DST_ONLY and let me know any other config should be included.


uint16_t queue_indices[] = {0,...29};

uint16_t queue_indices2[] = {30,..39};

 

action_rss1 = (struct rte_flow_action_rss){

                    .types = rss_conf.rss_hf,

                    .key_len = rss_conf.rss_key_len,

                    .queue_num = 30,

                    .key = rss_key,

                    .queue = queue_indices,

            };

 

action_rss2 = (struct rte_flow_action_rss){

                    .types = rss_conf.rss_hf,

                    .key_len = rss_conf.rss_key_len,

                    .queue_num = 10,

                    .key = rss_key,

                    .queue = queue_indices2,

            };

 

struct rte_flow_item pattern[] = {

                [0]={

                        .type = RTE_FLOW_ITEM_TYPE_ETH,

 

                },

                [1]={

                        .type = RTE_FLOW_ITEM_TYPE_IPV4,

                        .spec = &ipv4_spec,

                        .mask = &ipv4_mask,

                      

 

                },

                [2]={

                        .type = RTE_FLOW_ITEM_TYPE_UDP,

                },

 

                [3]={

                        .type = RTE_FLOW_ITEM_TYPE_END,

                }

        };

        struct rte_flow_item pattern2[] = {

                [0]={

                        .type = RTE_FLOW_ITEM_TYPE_ETH,

 

                },

              

                [1]={

                        .type = RTE_FLOW_ITEM_TYPE_IPV4,

                        .spec = &ipv4_spec2,

                        .mask = &ipv4_mask2,

                       

 

                },

                [2]={

                        .type = RTE_FLOW_ITEM_TYPE_UDP,

                },

 

                [3]={

                        .type = RTE_FLOW_ITEM_TYPE_END,

                }

        };

rte_flow_validate(bond_port, &attr, pattern, action_rss1, &error);

rte_flow_create(bond_port, &attr, pattern, action_rss1, &error);

 

rte_flow_validate(bond_port, &attr, pattern2, action_rss2, &error);

rte_flow_create(bond_port, &attr, pattern2, action_rss2, &error);


Pls let me know any other approach will match my requirement.

Thanks,
Raghavan V