From 4cc4dabe80eb7d19c20920b7ec20899d6a76a1dd Mon Sep 17 00:00:00 2001 From: Xavier Simonart Date: Tue, 28 May 2019 15:31:43 +0200 Subject: Added support for DPDK 19.02 and 19.05 This includes supporting following API changes - RTE_VER_... now in rte_config.h instead of rte_version.h - now seems required by - rte_sched_port_pkt_write takes extra argument - rte_sched_port_pkt_read_tree_path takes extra argument - enum rte_meter_color replaced by rte_color The extra argument, sched_port, is initialized based on qos_conf parameters. Modes such as qinq_encap4 uses sched_port when doing classification, but does not set qos_conf params. It inherits the sched_port from QoS Change-Id: If8312918241e7d482161a7538f53faac6c303e86 Signed-off-by: Xavier Simonart --- VNFs/DPPD-PROX/handle_qinq_encap4.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'VNFs/DPPD-PROX/handle_qinq_encap4.c') diff --git a/VNFs/DPPD-PROX/handle_qinq_encap4.c b/VNFs/DPPD-PROX/handle_qinq_encap4.c index 44e43456..e5c16af4 100644 --- a/VNFs/DPPD-PROX/handle_qinq_encap4.c +++ b/VNFs/DPPD-PROX/handle_qinq_encap4.c @@ -163,6 +163,10 @@ static void init_task_qinq_encap4(struct task_base *tbase, struct task_args *tar } /* task->src_mac[entry->port_idx] = *(uint64_t*)&prox_port_cfg[entry->port_idx].eth_addr; */ + if (targ->runtime_flags & TASK_CLASSIFY) { + int rc = init_port_sched(&task->sched_port, targ); + PROX_PANIC(rc, "Did not find any QoS task to transmit to => undefined sched_port parameters\n"); + } } static void arp_msg(struct task_base *tbase, void **data, uint16_t n_msgs) @@ -541,7 +545,7 @@ static inline uint8_t handle_qinq_encap4(struct task_qinq_encap4 *task, struct c uint8_t queue = task->dscp[cpe_pkt->ipv4_hdr.type_of_service >> 2] & 0x3; uint8_t tc = task->dscp[cpe_pkt->ipv4_hdr.type_of_service >> 2] >> 2; - rte_sched_port_pkt_write(mbuf, 0, entry->user, tc, queue, 0); + prox_rte_sched_port_pkt_write(task->sched_port, mbuf, 0, entry->user, tc, queue, 0); } #ifdef ENABLE_EXTRA_USER_STATISTICS task->stats_per_user[entry->user]++; -- cgit 1.2.3-korg