X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fnet%2Focteontx2%2Fotx2_rss.c;h=5e3f866819800d4e4c8a986fce662d47f47bbd86;hb=9a6ea33af9fac4c2a00a4bb595875a393a90b12d;hp=bc7b64387aba2c46503d13af99ecad99acbdea75;hpb=66c249f4d8836f9cab1166eba6c0828d4402afc0;p=dpdk.git diff --git a/drivers/net/octeontx2/otx2_rss.c b/drivers/net/octeontx2/otx2_rss.c index bc7b64387a..5e3f866819 100644 --- a/drivers/net/octeontx2/otx2_rss.c +++ b/drivers/net/octeontx2/otx2_rss.c @@ -210,6 +210,23 @@ otx2_rss_ethdev_to_nix(struct otx2_eth_dev *dev, uint64_t ethdev_rss, dev->rss_info.nix_rss = ethdev_rss; + if (ethdev_rss & ETH_RSS_L2_PAYLOAD && + dev->npc_flow.switch_header_type == OTX2_PRIV_FLAGS_LEN_90B) { + flowkey_cfg |= FLOW_KEY_TYPE_CH_LEN_90B; + } + + if (ethdev_rss & ETH_RSS_L3_SRC_ONLY) + flowkey_cfg |= FLOW_KEY_TYPE_L3_SRC; + + if (ethdev_rss & ETH_RSS_L3_DST_ONLY) + flowkey_cfg |= FLOW_KEY_TYPE_L3_DST; + + if (ethdev_rss & ETH_RSS_L4_SRC_ONLY) + flowkey_cfg |= FLOW_KEY_TYPE_L4_SRC; + + if (ethdev_rss & ETH_RSS_L4_DST_ONLY) + flowkey_cfg |= FLOW_KEY_TYPE_L4_DST; + if (ethdev_rss & RSS_IPV4_ENABLE) flowkey_cfg |= flow_key_type[rss_level][RSS_IPV4_INDEX]; @@ -341,7 +358,7 @@ otx2_nix_rss_config(struct rte_eth_dev *eth_dev) int rc; /* Skip further configuration if selected mode is not RSS */ - if (eth_dev->data->dev_conf.rxmode.mq_mode != ETH_MQ_RX_RSS) + if (eth_dev->data->dev_conf.rxmode.mq_mode != ETH_MQ_RX_RSS || !qcnt) return 0; /* Update default RSS key and cfg */