public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Sasha Levin <sasha.levin@oracle.com>
To: Eric Northup <digitaleric@google.com>
Cc: Pekka Enberg <penberg@kernel.org>,
	will.deacon@arm.com, marc.zyngier@arm.com,
	KVM <kvm@vger.kernel.org>,
	asias@redhat.com, jasowang@redhat.com, rusty@rustcorp.com.au,
	"Michael S. Tsirkin" <mst@redhat.com>
Subject: Re: [PATCH] kvm tools: virtio-net mergable rx buffers
Date: Tue, 23 Apr 2013 22:51:00 -0400	[thread overview]
Message-ID: <51774894.7080008@oracle.com> (raw)
In-Reply-To: <CAG7+5M27_sUGUOk_erV1-QdJ2VFKK6LVXpkdTFTpiWgDzOV50w@mail.gmail.com>

On 04/23/2013 12:35 PM, Eric Northup wrote:
> Do you care about guests with drivers that don't negotiate
> VIRTIO_NET_F_MRG_RXBUF?

We usually try to keep backward compatibility, but in this case
mergable RX buffers are about 5 years old now, so it's safe to
assume they'll be running in any guest.

Unless there is a specific reason to allow working without them
I'd rather keep the code simple in this case.

> On Mon, Apr 22, 2013 at 5:32 PM, Sasha Levin <sasha.levin@oracle.com> wrote:
>> +                               copied = memcpy_toiovecend(iov, in, buffer, len);
>> +                               len -= copied;
>> +                               hdr->num_buffers++;
>> +                               virt_queue__set_used_elem(vq, head, copied);
>> +                               if (len == 0)
>> +                                       break;
>> +                               head = virt_queue__get_iov(vq, iov, &out, &in, kvm);
> 
> Need to check that virt_queue__available(vq) first?

Yup. I wonder why it didn't blow up running 'ping -f' with a huge packet size.


Thanks,
Sasha


  reply	other threads:[~2013-04-24  2:51 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-23  0:32 [PATCH] kvm tools: virtio-net mergable rx buffers Sasha Levin
2013-04-23  9:06 ` Pekka Enberg
2013-04-23 14:19   ` Asias He
2013-04-23 15:01 ` Sasha Levin
2013-04-23 16:35 ` Eric Northup
2013-04-24  2:51   ` Sasha Levin [this message]
2013-04-24  6:51     ` Pekka Enberg
2013-04-24  9:23       ` Michael S. Tsirkin
2013-04-29  0:44         ` Rusty Russell
2013-04-29  2:36           ` Sasha Levin
2013-04-24  5:32 ` Asias He
2013-04-24  9:35   ` Michael S. Tsirkin

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=51774894.7080008@oracle.com \
    --to=sasha.levin@oracle.com \
    --cc=asias@redhat.com \
    --cc=digitaleric@google.com \
    --cc=jasowang@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=marc.zyngier@arm.com \
    --cc=mst@redhat.com \
    --cc=penberg@kernel.org \
    --cc=rusty@rustcorp.com.au \
    --cc=will.deacon@arm.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