netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Avi Kivity <avi@redhat.com>
To: Sridhar Samudrala <sri@us.ibm.com>
Cc: kvm@vger.kernel.org, herbert.xu@redhat.com,
	rusty@rustcorp.com.au, davem@davemloft.net,
	netdev@vger.kernel.org
Subject: Re: [PATCH qemu-kvm] Enable UFO on virtio-net/tap devices
Date: Sun, 07 Jun 2009 09:21:39 +0300	[thread overview]
Message-ID: <4A2B5C73.5050907@redhat.com> (raw)
In-Reply-To: <1244247408.1526.174.camel@w-sridhar.beaverton.ibm.com>

Sridhar Samudrala wrote:
> Enable UFO on the host tap device if supported and allow setting UFO
> on virtio-net in the guest.
>
> Signed-off-by: Sridhar Samudrala <sri@us.ibm.com>
>
>
> diff --git a/hw/virtio-net.c b/hw/virtio-net.c
> index 3c77b99..8a53e27 100644
> --- a/hw/virtio-net.c
> +++ b/hw/virtio-net.c
> @@ -134,7 +134,8 @@ static uint32_t virtio_net_get_features(VirtIODevice *vdev)
>          features |= (1 << VIRTIO_NET_F_HOST_TSO6);
>          features |= (1 << VIRTIO_NET_F_HOST_ECN);
>          features |= (1 << VIRTIO_NET_F_MRG_RXBUF);
> -        /* Kernel can't actually handle UFO in software currently. */
> +       // features |= (1 << VIRTIO_NET_F_HOST_UFO);
> +        features |= (1 << VIRTIO_NET_F_GUEST_UFO);
>   

Where are these defined?

> @@ -990,8 +990,13 @@ static int tap_probe_vnet_hdr(int fd)
>  }
>  
>  #ifdef TUNSETOFFLOAD
> +
> +#ifndef TUN_F_UFO
> +#define TUN_F_UFO	0x10
> +#endif
> +
>   

Should just use the definition in the kernel header.

-- 
Do not meddle in the internals of kernels, for they are subtle and quick to panic.


  parent reply	other threads:[~2009-06-07  6:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-06  0:16 [PATCH qemu-kvm] Enable UFO on virtio-net/tap devices Sridhar Samudrala
2009-06-06  7:33 ` Jan Kiszka
2009-06-08 16:32   ` Sridhar Samudrala
2009-06-07  6:21 ` Avi Kivity [this message]
2009-06-08 16:40   ` Sridhar Samudrala

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4A2B5C73.5050907@redhat.com \
    --to=avi@redhat.com \
    --cc=davem@davemloft.net \
    --cc=herbert.xu@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=rusty@rustcorp.com.au \
    --cc=sri@us.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).