* [PATCH] net/cpfl: fix RSS lookup table configuration
@ 2023-07-03 11:28 beilei.xing
2023-07-03 7:32 ` Wu, Jingjing
0 siblings, 1 reply; 3+ messages in thread
From: beilei.xing @ 2023-07-03 11:28 UTC (permalink / raw)
To: jingjing.wu; +Cc: dev, Beilei Xing
From: Beilei Xing <beilei.xing@intel.com>
Ethdev Rx queues includes normal data queues and hairpin queues,
RSS should direct traffic only to the normal data queues.
Fixes: fda03330fcaa ("net/cpfl: support hairpin queue configuration")
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
---
drivers/net/cpfl/cpfl_ethdev.c | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/drivers/net/cpfl/cpfl_ethdev.c b/drivers/net/cpfl/cpfl_ethdev.c
index 9755ffe508..c4ca9343c3 100644
--- a/drivers/net/cpfl/cpfl_ethdev.c
+++ b/drivers/net/cpfl/cpfl_ethdev.c
@@ -817,6 +817,24 @@ cpfl_rxq_hairpin_mz_bind(struct rte_eth_dev *dev)
}
}
+static int
+cpfl_rss_lut_config(struct cpfl_vport *cpfl_vport, uint16_t nb_q)
+{
+ struct idpf_vport *vport = &cpfl_vport->base;
+ uint16_t lut_size = vport->rss_lut_size;
+ uint16_t i;
+ int ret;
+
+ for (i = 0; i < lut_size; i++)
+ vport->rss_lut[i] = i % nb_q;
+
+ ret = idpf_vc_rss_lut_set(vport);
+ if (ret)
+ PMD_INIT_LOG(ERR, "Failed to configure RSS lut");
+
+ return ret;
+}
+
static int
cpfl_start_queues(struct rte_eth_dev *dev)
{
@@ -951,6 +969,10 @@ cpfl_start_queues(struct rte_eth_dev *dev)
}
}
+ /* re-configure RSS lut if there's hairpin queue */
+ if (cpfl_vport->nb_p2p_rxq > 0)
+ err = cpfl_rss_lut_config(cpfl_vport, cpfl_vport->nb_data_rxq);
+
return err;
}
--
2.34.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [PATCH] net/cpfl: fix RSS lookup table configuration
2023-07-03 11:28 [PATCH] net/cpfl: fix RSS lookup table configuration beilei.xing
@ 2023-07-03 7:32 ` Wu, Jingjing
2023-07-04 1:23 ` Zhang, Qi Z
0 siblings, 1 reply; 3+ messages in thread
From: Wu, Jingjing @ 2023-07-03 7:32 UTC (permalink / raw)
To: Xing, Beilei; +Cc: dev
> -----Original Message-----
> From: Xing, Beilei <beilei.xing@intel.com>
> Sent: Monday, July 3, 2023 7:28 PM
> To: Wu, Jingjing <jingjing.wu@intel.com>
> Cc: dev@dpdk.org; Xing, Beilei <beilei.xing@intel.com>
> Subject: [PATCH] net/cpfl: fix RSS lookup table configuration
>
> From: Beilei Xing <beilei.xing@intel.com>
>
> Ethdev Rx queues includes normal data queues and hairpin queues,
> RSS should direct traffic only to the normal data queues.
>
> Fixes: fda03330fcaa ("net/cpfl: support hairpin queue configuration")
>
> Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [PATCH] net/cpfl: fix RSS lookup table configuration
2023-07-03 7:32 ` Wu, Jingjing
@ 2023-07-04 1:23 ` Zhang, Qi Z
0 siblings, 0 replies; 3+ messages in thread
From: Zhang, Qi Z @ 2023-07-04 1:23 UTC (permalink / raw)
To: Wu, Jingjing, Xing, Beilei; +Cc: dev
> -----Original Message-----
> From: Wu, Jingjing <jingjing.wu@intel.com>
> Sent: Monday, July 3, 2023 3:33 PM
> To: Xing, Beilei <beilei.xing@intel.com>
> Cc: dev@dpdk.org
> Subject: RE: [PATCH] net/cpfl: fix RSS lookup table configuration
>
>
>
> > -----Original Message-----
> > From: Xing, Beilei <beilei.xing@intel.com>
> > Sent: Monday, July 3, 2023 7:28 PM
> > To: Wu, Jingjing <jingjing.wu@intel.com>
> > Cc: dev@dpdk.org; Xing, Beilei <beilei.xing@intel.com>
> > Subject: [PATCH] net/cpfl: fix RSS lookup table configuration
> >
> > From: Beilei Xing <beilei.xing@intel.com>
> >
> > Ethdev Rx queues includes normal data queues and hairpin queues, RSS
> > should direct traffic only to the normal data queues.
> >
> > Fixes: fda03330fcaa ("net/cpfl: support hairpin queue configuration")
> >
> > Signed-off-by: Beilei Xing <beilei.xing@intel.com>
>
> Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Applied to dpdk-next-net-intel.
Thanks
Qi
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-07-04 1:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-03 11:28 [PATCH] net/cpfl: fix RSS lookup table configuration beilei.xing
2023-07-03 7:32 ` Wu, Jingjing
2023-07-04 1:23 ` Zhang, Qi Z
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).