From ad584f4d9da98fa5fbdc19a69b63b323e27458dc Mon Sep 17 00:00:00 2001 From: Xavier Simonart Date: Tue, 26 May 2020 11:46:41 +0200 Subject: Fix source mac address when applying imix Change-Id: I8cbbe1b08af9b5472c304f2fba3635f0a084fdd8 Signed-off-by: Xavier Simonart --- VNFs/DPPD-PROX/handle_gen.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/VNFs/DPPD-PROX/handle_gen.c b/VNFs/DPPD-PROX/handle_gen.c index ac75f221..427564c9 100644 --- a/VNFs/DPPD-PROX/handle_gen.c +++ b/VNFs/DPPD-PROX/handle_gen.c @@ -712,6 +712,9 @@ static int task_gen_set_eth_ip_udp_sizes(struct task_gen *task, uint32_t n_orig_ template = &task->pkt_template[k]; template->len = pkt_sizes[j]; rte_memcpy(template->buf, task->pkt_template_orig[i].buf, pkt_sizes[j]); + if (task->flags & TASK_OVERWRITE_SRC_MAC_WITH_PORT_MAC) { + rte_memcpy(&template->buf[sizeof(prox_rte_ether_addr)], &task->src_mac, sizeof(prox_rte_ether_addr)); + } parse_l2_l3_len(template->buf, &template->l2_len, &template->l3_len, template->len); if (template->l2_len == 0) continue; -- cgit 1.2.3-korg