DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH 01/10] common/cnxk: sync VF root weight with kernel
@ 2024-05-17  7:44 Nithin Dabilpuram
  2024-05-17  7:44 ` [PATCH 02/10] net/cnxk: set VF default root schedule weight Nithin Dabilpuram
                   ` (9 more replies)
  0 siblings, 10 replies; 24+ messages in thread
From: Nithin Dabilpuram @ 2024-05-17  7:44 UTC (permalink / raw)
  To: Nithin Dabilpuram, Kiran Kumar K, Sunil Kumar Kori, Satha Rao,
	Harman Kalra
  Cc: jerinj, dev

From: Satha Rao <skoteshwar@marvell.com>

By default set VF root scheduling weight same as other kernel
configured VFs. Also fix a compilation issue when cflags has
-Werror=shadow=compatible-local.

Signed-off-by: Satha Rao <skoteshwar@marvell.com>
---
 drivers/common/cnxk/roc_nix.h       | 1 +
 drivers/common/cnxk/roc_nix_queue.c | 3 ++-
 drivers/common/cnxk/roc_nix_tm.c    | 6 +++++-
 3 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/drivers/common/cnxk/roc_nix.h b/drivers/common/cnxk/roc_nix.h
index bd3e540f45..63bcd5b25e 100644
--- a/drivers/common/cnxk/roc_nix.h
+++ b/drivers/common/cnxk/roc_nix.h
@@ -473,6 +473,7 @@ struct roc_nix {
 	bool force_rx_aura_bp;
 	bool custom_meta_aura_ena;
 	bool rx_inj_ena;
+	uint32_t root_sched_weight;
 	/* End of input parameters */
 	/* LMT line base for "Per Core Tx LMT line" mode*/
 	uintptr_t lmt_base;
diff --git a/drivers/common/cnxk/roc_nix_queue.c b/drivers/common/cnxk/roc_nix_queue.c
index ae4e0ea40c..f5441e0e6b 100644
--- a/drivers/common/cnxk/roc_nix_queue.c
+++ b/drivers/common/cnxk/roc_nix_queue.c
@@ -1030,7 +1030,8 @@ sqb_pool_populate(struct roc_nix *roc_nix, struct roc_nix_sq *sq)
 	thr = PLT_DIV_CEIL((nb_sqb_bufs * ROC_NIX_SQB_THRESH), 100);
 	nb_sqb_bufs += NIX_SQB_PREFETCH;
 	/* Clamp up the SQB count */
-	nb_sqb_bufs = PLT_MIN(roc_nix->max_sqb_count, (uint16_t)PLT_MAX(NIX_DEF_SQB, nb_sqb_bufs));
+	nb_sqb_bufs = PLT_MAX(NIX_DEF_SQB, nb_sqb_bufs);
+	nb_sqb_bufs = PLT_MIN(roc_nix->max_sqb_count, (uint16_t)nb_sqb_bufs);
 
 	sq->nb_sqb_bufs = nb_sqb_bufs;
 	sq->sqes_per_sqb_log2 = (uint16_t)plt_log2_u32(sqes_per_sqb);
diff --git a/drivers/common/cnxk/roc_nix_tm.c b/drivers/common/cnxk/roc_nix_tm.c
index 4e6a28f827..ac522f8235 100644
--- a/drivers/common/cnxk/roc_nix_tm.c
+++ b/drivers/common/cnxk/roc_nix_tm.c
@@ -1589,7 +1589,11 @@ nix_tm_prepare_default_tree(struct roc_nix *roc_nix)
 		node->id = nonleaf_id;
 		node->parent_id = parent;
 		node->priority = 0;
-		node->weight = NIX_TM_DFLT_RR_WT;
+		/* Default VF root RR_QUANTUM is in sync with kernel */
+		if (lvl == ROC_TM_LVL_ROOT && !nix_tm_have_tl1_access(nix))
+			node->weight = roc_nix->root_sched_weight;
+		else
+			node->weight = NIX_TM_DFLT_RR_WT;
 		node->shaper_profile_id = ROC_NIX_TM_SHAPER_PROFILE_NONE;
 		node->lvl = lvl;
 		node->tree = ROC_NIX_TM_DEFAULT;
-- 
2.25.1


^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2024-05-28 16:04 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-17  7:44 [PATCH 01/10] common/cnxk: sync VF root weight with kernel Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 02/10] net/cnxk: set VF default root schedule weight Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 03/10] net/cnxk: fix extbuf handling for multisegment packet Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 04/10] common/cnxk: override UDP encap ports with session data Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 05/10] net/cnxk: update SA userdata and keep original cookie Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 06/10] net/cnxk: add option to disable custom meta aura Nithin Dabilpuram
2024-05-27 17:29   ` Jerin Jacob
2024-05-17  7:44 ` [PATCH 07/10] net/cnxk: fix issue with outbound security higher pkt burst Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 08/10] common/cnxk: add API to reset CGX stats Nithin Dabilpuram
2024-05-17  7:44 ` [PATCH 09/10] net/cnxk: clear CGX stats during xstats reset Nithin Dabilpuram
2024-05-27 17:28   ` Jerin Jacob
2024-05-17  7:44 ` [PATCH 10/10] net/cnxk: define CPT HW result format for PMD API Nithin Dabilpuram
2024-05-27 17:27   ` Jerin Jacob
2024-05-28  7:05 ` [PATCH v2 01/10] common/cnxk: sync VF root weight with kernel Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 02/10] net/cnxk: set VF default root schedule weight Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 03/10] net/cnxk: fix extbuf handling for multisegment packet Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 04/10] common/cnxk: override UDP encap ports with session data Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 05/10] net/cnxk: update SA userdata and keep original cookie Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 06/10] net/cnxk: add option to disable custom meta aura Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 07/10] net/cnxk: fix issue with outbound security higher pkt burst Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 08/10] common/cnxk: add API to reset CGX stats Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 09/10] net/cnxk: fix xstats reset Nithin Dabilpuram
2024-05-28  7:05   ` [PATCH v2 10/10] net/cnxk: define CPT HW result format for PMD API Nithin Dabilpuram
2024-05-28 16:03     ` Jerin Jacob

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).