[PATCH] net/ice: remove unreachable TM weight mode check
Artem Novikov
naa at amicon.ru
Mon Nov 16 12:15:54 CET 2026
In ice_node_param_check(), non-leaf nodes reject any non-NULL
wfq_weight_mode pointer and return immediately.
The later else-if branch checks wfq_weight_mode again, so it can only be
reached when wfq_weight_mode is NULL. As a result, the condition is always
false and the "WFP should be byte mode" error path is unreachable.
Remove the dead branch. No functional change.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
Fixes: 8c481c3bb65b ("net/ice: support queue and queue group bandwidth limit")
Cc: stable at dpdk.org
Signed-off-by: Artem Novikov <naa at amicon.ru>
---
drivers/net/intel/ice/ice_tm.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/drivers/net/intel/ice/ice_tm.c b/drivers/net/intel/ice/ice_tm.c
index 2e6ef9c264..6c4c3022ec 100644
--- a/drivers/net/intel/ice/ice_tm.c
+++ b/drivers/net/intel/ice/ice_tm.c
@@ -144,12 +144,6 @@ ice_node_param_check(uint32_t node_id,
RTE_TM_ERROR_TYPE_NODE_PARAMS_N_SP_PRIORITIES;
error->message = "SP priority not supported";
return -EINVAL;
- } else if (params->nonleaf.wfq_weight_mode &&
- !(*params->nonleaf.wfq_weight_mode)) {
- error->type =
- RTE_TM_ERROR_TYPE_NODE_PARAMS_WFQ_WEIGHT_MODE;
- error->message = "WFP should be byte mode";
- return -EINVAL;
}
return 0;
More information about the dev
mailing list