summaryrefslogtreecommitdiffstats
path: root/VNFs/DPPD-PROX/handle_qos.c
diff options
context:
space:
mode:
authorHeinrich Kuhn <heinrich.kuhn@corigine.com>2021-08-18 16:21:39 +0200
committerLuc Provoost <luc.provoost@intel.com>2021-09-13 13:22:32 +0000
commit75597545ef748d7113591cdbfc8d1aaa88cf15cb (patch)
tree2d00c7766d341785cb1a17b72f971e1383f257d9 /VNFs/DPPD-PROX/handle_qos.c
parentd87ea3dfce75c5993564a60cadb81bfa75f20c80 (diff)
Use updated DPDK scheduling schema in Prox
The scheduling infrastructure in DPDK has changed somewhat in DPDK 20.11 and up. This patch adds the needed compatibly code to make use of the new layout in DPDK. The bulk of the changes revolve around moving tb/tc rates and period fields from rte_sched_subport_params to a new struct called rte_sched_subport_profile_params Signed-off-by: Heinrich Kuhn <heinrich.kuhn@corigine.com> Signed-off-by: Simon Horman <simon.horman@corigine.com> Change-Id: Ie365903b972528eaa9324c707fe3868610f51993
Diffstat (limited to 'VNFs/DPPD-PROX/handle_qos.c')
-rw-r--r--VNFs/DPPD-PROX/handle_qos.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/VNFs/DPPD-PROX/handle_qos.c b/VNFs/DPPD-PROX/handle_qos.c
index 5af7a310..de9548f6 100644
--- a/VNFs/DPPD-PROX/handle_qos.c
+++ b/VNFs/DPPD-PROX/handle_qos.c
@@ -135,7 +135,11 @@ static void init_task_qos(struct task_base *tbase, struct task_args *targ)
PROX_PANIC(task->sched_port == NULL, "failed to create sched_port");
plog_info("number of pipes: %d\n\n", targ->qos_conf.port_params.n_pipes_per_subport);
+#if RTE_VERSION >= RTE_VERSION_NUM(20,11,0,0)
+ int err = rte_sched_subport_config(task->sched_port, 0, targ->qos_conf.subport_params, 0);
+#else
int err = rte_sched_subport_config(task->sched_port, 0, targ->qos_conf.subport_params);
+#endif
PROX_PANIC(err != 0, "Failed setting up sched_port subport, error: %d", err);
/* only single subport and single pipe profile is supported */