Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1546904
| From | John Fastabend <john.fastabend@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH net 5/9] virtio-net: unbreak csumed packets for XDP_PASS |
| Date | 2016-12-23 17:00 +0100 |
| Message-ID | <sRAqe-kn-27@gated-at.bofh.it> (permalink) |
| References | <sRzaN-833-3@gated-at.bofh.it> <sRzku-86G-21@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 16-12-23 06:37 AM, Jason Wang wrote:
> We drop csumed packet when do XDP for packets. This breaks
> XDP_PASS when GUEST_CSUM is supported. Fix this by allowing csum flag
> to be set. With this patch, simple TCP works for XDP_PASS.
>
> Cc: John Fastabend <john.r.fastabend@intel.com>
> Signed-off-by: Jason Wang <jasowang@redhat.com>
> ---
> drivers/net/virtio_net.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
> index 470293e..0778dc8 100644
> --- a/drivers/net/virtio_net.c
> +++ b/drivers/net/virtio_net.c
> @@ -440,7 +440,7 @@ static struct sk_buff *receive_big(struct net_device *dev,
> struct virtio_net_hdr_mrg_rxbuf *hdr = buf;
> u32 act;
>
> - if (unlikely(hdr->hdr.gso_type || hdr->hdr.flags))
> + if (unlikely(hdr->hdr.gso_type))
> goto err_xdp;
> act = do_xdp_prog(vi, rq, xdp_prog, page, 0, len);
> switch (act) {
> @@ -572,7 +572,7 @@ static struct sk_buff *receive_mergeable(struct net_device *dev,
> * the receive path after XDP is loaded. In practice I
> * was not able to create this condition.
> */
> - if (unlikely(hdr->hdr.gso_type || hdr->hdr.flags))
> + if (unlikely(hdr->hdr.gso_type))
> goto err_xdp;
>
> act = do_xdp_prog(vi, rq, xdp_prog, xdp_page, offset, len);
>
Acked-by: John Fastabend <john.r.fastabend@intel.com>
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH net 0/9] several fixups for virtio-net XDP Jason Wang <jasowang@redhat.com> - 2016-12-23 15:40 +0100
[PATCH net 4/9] virtio-net: correctly handle XDP_PASS for linearized packets Jason Wang <jasowang@redhat.com> - 2016-12-23 15:40 +0100
Re: [PATCH net 4/9] virtio-net: correctly handle XDP_PASS for linearized packets John Fastabend <john.fastabend@gmail.com> - 2016-12-23 17:00 +0100
Re: [PATCH net 4/9] virtio-net: correctly handle XDP_PASS for linearized packets Jason Wang <jasowang@redhat.com> - 2016-12-26 03:40 +0100
[PATCH net 2/9] virtio-net: correctly xmit linearized page on XDP_TX Jason Wang <jasowang@redhat.com> - 2016-12-23 15:40 +0100
Re: [PATCH net 2/9] virtio-net: correctly xmit linearized page on XDP_TX John Fastabend <john.fastabend@gmail.com> - 2016-12-23 16:50 +0100
[PATCH net 8/9] virtio-net: remove big packet XDP codes Jason Wang <jasowang@redhat.com> - 2016-12-23 15:40 +0100
[PATCH net 9/9] virtio-net: XDP support for small buffers Jason Wang <jasowang@redhat.com> - 2016-12-23 15:50 +0100
Re: [PATCH net 9/9] virtio-net: XDP support for small buffers John Fastabend <john.fastabend@gmail.com> - 2016-12-23 18:00 +0100
Re: [PATCH net 9/9] virtio-net: XDP support for small buffers John Fastabend <john.fastabend@gmail.com> - 2017-01-02 23:50 +0100
Re: [PATCH net 9/9] virtio-net: XDP support for small buffers Jason Wang <jasowang@redhat.com> - 2017-01-03 07:20 +0100
Re: [PATCH net 9/9] virtio-net: XDP support for small buffers John Fastabend <john.fastabend@gmail.com> - 2017-01-03 17:50 +0100
[PATCH net 5/9] virtio-net: unbreak csumed packets for XDP_PASS Jason Wang <jasowang@redhat.com> - 2016-12-23 15:50 +0100
Re: [PATCH net 5/9] virtio-net: unbreak csumed packets for XDP_PASS John Fastabend <john.fastabend@gmail.com> - 2016-12-23 17:00 +0100
Re: [PATCH net 0/9] several fixups for virtio-net XDP John Fastabend <john.fastabend@gmail.com> - 2016-12-23 18:20 +0100
Re: [PATCH net 0/9] several fixups for virtio-net XDP Jason Wang <jasowang@redhat.com> - 2016-12-26 03:40 +0100
Re: [PATCH net 0/9] several fixups for virtio-net XDP David Miller <davem@davemloft.net> - 2016-12-23 19:50 +0100
csiph-web