From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adrien Mazarguil Subject: [PATCH 1/2] app/testpmd: use correct hardware address in ARP replies Date: Fri, 22 May 2015 13:07:31 +0200 Message-ID: <1432292852-15701-1-git-send-email-adrien.mazarguil@6wind.com> To: dev@dpdk.org Return-path: Received: from mail-wg0-f45.google.com (mail-wg0-f45.google.com [74.125.82.45]) by dpdk.org (Postfix) with ESMTP id 74A0B5697 for ; Fri, 22 May 2015 13:07:43 +0200 (CEST) Received: by wghq2 with SMTP id q2so14445957wgh.1 for ; Fri, 22 May 2015 04:07:43 -0700 (PDT) Received: from 6wind.com (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by mx.google.com with ESMTPSA id ch2sm6988793wib.18.2015.05.22.04.07.41 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 22 May 2015 04:07:42 -0700 (PDT) List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" In the icmpecho forwarding mode, ARP replies from testpmd contain invalid zero-filled MAC addresses. This is broken since the commit below. Fixes: 31db4d38de72 ("net: change arp header struct declaration") Signed-off-by: Adrien Mazarguil Acked-by: Ivan Boule --- app/test-pmd/icmpecho.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test-pmd/icmpecho.c b/app/test-pmd/icmpecho.c index 010c5a9..c5933f4 100644 --- a/app/test-pmd/icmpecho.c +++ b/app/test-pmd/icmpecho.c @@ -400,7 +400,7 @@ reply_to_icmp_echo_rqsts(struct fwd_stream *fs) arp_h->arp_op = rte_cpu_to_be_16(ARP_OP_REPLY); ether_addr_copy(&arp_h->arp_data.arp_tha, ð_addr); ether_addr_copy(&arp_h->arp_data.arp_sha, &arp_h->arp_data.arp_tha); - ether_addr_copy(ð_addr, &arp_h->arp_data.arp_sha); + ether_addr_copy(ð_h->s_addr, &arp_h->arp_data.arp_sha); /* Swap IP addresses in ARP payload */ ip_addr = arp_h->arp_data.arp_sip; -- 2.1.0