From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f50.google.com (mail-wm0-f50.google.com [74.125.82.50]) by dpdk.org (Postfix) with ESMTP id 78F005A54 for ; Fri, 22 Jul 2016 00:28:17 +0200 (CEST) Received: by mail-wm0-f50.google.com with SMTP id o80so42513554wme.1 for ; Thu, 21 Jul 2016 15:28:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:user-agent:in-reply-to :references:mime-version:content-transfer-encoding; bh=K1Wc2ksA6g5yxaCkO0lFAuAC7xu3kTTs0r/6GzY0cC8=; b=Zh+4gTsfoHTaF0IvEUO37elQjQd797qv+6UO0plGJtkgco8Tqep4IbE3CIv9AD7qeQ TOgsnb66Uqhk1R35XmJ7IJc6u1nCRJ4hbSwlBJNye2XfyQdGsdR9qAW9DWQrNJJ4EKwy 2hirCi12XwXRZSeY4UWV4cgVm8Abu4yPd5icsFEb+jCM083p5gEPIYkk7657dSylkjQ8 8WF0IS1bGkJHxWK4a0Ne1LQV3YmTcwL7gEaSrdqKFdP3srH9VH+LVWpj1bm7hVIk/cw/ QXYeR/pAUKQD7ReafqC+oGdMg0fczM8Ab1JRx/6OlhvUYAkjXsOfiREqGEtqorsuj1eO WJRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=K1Wc2ksA6g5yxaCkO0lFAuAC7xu3kTTs0r/6GzY0cC8=; b=hJ3rQkPUO0MkxkqD6X0Nhobi2Dh2yEsDlKBY0YF0ld0RpCOwRpkB4ILgATkICPMLDb 8NM0gIce6w6BOgFZr34CkxxAYw4t1xw4WXiEZ6tsz0n0VfFcwy4HvCTNkhM0zr5QrEBk Uaby9YruCVh0cLYo3ptY4NDvm5+SbARI5QF1zp26qJfHfkoymYcx01RRYcT6WZ63JVxx wcdFZQGles6df79cTJpl4sRTd11ttvsYYFQKRTOJYUzqCN6TB25YwHbxa0+qXF574Uvj /LJeQvjc/cGxdFmVrOt0RBU9yjoh1DcJVdCrNdxLEIOFGjMDHeLLI6FLesVUVqER/ry/ 5qHg== X-Gm-Message-State: ALyK8tKkpGxIB4wTuqDAwi5RGRoynnEt0dVRr0i/JLlO1c7lgI+pHh+idLyl6wDUc4j2LOIa X-Received: by 10.28.157.214 with SMTP id g205mr21589632wme.34.1469140097279; Thu, 21 Jul 2016 15:28:17 -0700 (PDT) Received: from xps13.localnet (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id v134sm7736426wmf.10.2016.07.21.15.28.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 21 Jul 2016 15:28:16 -0700 (PDT) From: Thomas Monjalon To: Olivier Matz Cc: dev@dpdk.org, Yuanhan Liu , jianfeng.tan@intel.com, huawei.xie@intel.com Date: Fri, 22 Jul 2016 00:28:15 +0200 Message-ID: <3319812.8v20LhbOem@xps13> User-Agent: KMail/4.14.10 (Linux/4.5.4-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <20160721082851.GC28708@yliu-dev.sh.intel.com> References: <1468931519-7381-1-git-send-email-olivier.matz@6wind.com> <20160721082851.GC28708@yliu-dev.sh.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH] virtio: fix packet corruption X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Jul 2016 22:28:17 -0000 2016-07-21 16:28, Yuanhan Liu: > On Tue, Jul 19, 2016 at 02:31:59PM +0200, Olivier Matz wrote: > > The support of virtio-user changed the way the mbuf dma address is > > retrieved, using a physical address in case of virtio-pci and a virtual > > address in case of virtio-user. > > > > This change introduced some possible memory corruption in packets, > > replacing: > > m->buf_physaddr + RTE_PKTMBUF_HEADROOM > > by: > > m->buf_physaddr + m->data_off (through a macro) > > > > This patch fixes this issue, restoring the original behavior. > > > > By the way, it also rework the macros, adding a "VIRTIO_" prefix and > > API comments. > > > > Fixes: f24f8f9fee8a ("net/virtio: allow virtual address to fill vring descriptors") > > > > Signed-off-by: Olivier Matz > > Thanks for the fix! > > Acked-by: Yuanhan Liu Applied, thanks