Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965041AbcLWPru (ORCPT ); Fri, 23 Dec 2016 10:47:50 -0500 Received: from mail-pg0-f66.google.com ([74.125.83.66]:35213 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756025AbcLWPrs (ORCPT ); Fri, 23 Dec 2016 10:47:48 -0500 Subject: Re: [PATCH net 2/9] virtio-net: correctly xmit linearized page on XDP_TX To: Jason Wang , mst@redhat.com, virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <1482503852-12438-1-git-send-email-jasowang@redhat.com> <1482503852-12438-3-git-send-email-jasowang@redhat.com> Cc: john.r.fastabend@intel.com From: John Fastabend Message-ID: <585D4715.2070407@gmail.com> Date: Fri, 23 Dec 2016 07:47:33 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <1482503852-12438-3-git-send-email-jasowang@redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1085 Lines: 29 On 16-12-23 06:37 AM, Jason Wang wrote: > After we linearize page, we should xmit this page instead of the page > of first buffer which may lead unexpected result. With this patch, we > can see correct packet during XDP_TX. > > Cc: John Fastabend > Signed-off-by: Jason Wang > --- > drivers/net/virtio_net.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c > index 1067253..fe4562d 100644 > --- a/drivers/net/virtio_net.c > +++ b/drivers/net/virtio_net.c > @@ -572,7 +572,7 @@ static struct sk_buff *receive_mergeable(struct net_device *dev, > if (unlikely(hdr->hdr.gso_type || hdr->hdr.flags)) > goto err_xdp; > > - act = do_xdp_prog(vi, rq, xdp_prog, page, offset, len); > + act = do_xdp_prog(vi, rq, xdp_prog, xdp_page, offset, len); > switch (act) { > case XDP_PASS: > if (unlikely(xdp_page != page)) > Thanks clumsy merge conflict resolution between v4 and v6 versions :/ Acked-by: John Fastabend