From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id AF9681B53 for ; Fri, 29 Dec 2017 03:34:00 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Dec 2017 18:33:59 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,473,1508828400"; d="scan'208";a="190696566" Received: from dpdk-dev.sh.intel.com ([10.67.111.147]) by fmsmga006.fm.intel.com with ESMTP; 28 Dec 2017 18:33:58 -0800 From: Junjie Chen To: yliu@fridaylinux.org, maxime.coquelin@redhat.com Cc: dev@dpdk.org, Junjie Chen Date: Fri, 29 Dec 2017 05:14:23 -0500 Message-Id: <1514542463-146522-1-git-send-email-junjie.j.chen@intel.com> X-Mailer: git-send-email 2.0.1 Subject: [dpdk-dev] [PATCH] examples/vhost: fix sending arp packet to self X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Dec 2017 02:34:01 -0000 ARP packets are not dropped when dest vdev is itself, which breaks RX ring inconspicuously. Signed-off-by: Junjie Chen --- examples/vhost/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/vhost/main.c b/examples/vhost/main.c index 89a61f0..10a7f5d 100644 --- a/examples/vhost/main.c +++ b/examples/vhost/main.c @@ -964,7 +964,8 @@ virtio_tx_route(struct vhost_dev *vdev, struct rte_mbuf *m, uint16_t vlan_tag) struct vhost_dev *vdev2; TAILQ_FOREACH(vdev2, &vhost_dev_list, global_vdev_entry) { - virtio_xmit(vdev2, vdev, m); + if (vdev2 != vdev) + virtio_xmit(vdev2, vdev, m); } goto queue2nic; } -- 2.0.1