Discussion of the VIRTIO specification
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Vitaly Mireyno <vmireyno@marvell.com>
Cc: Jason Wang <jasowang@redhat.com>,
	"virtio-comment@lists.oasis-open.org"
	<virtio-comment@lists.oasis-open.org>
Subject: Re: [virtio-comment] Re: [EXT] Re: [virtio-comment] Re: [PATCH] virtio-net: Add equal-sized receive buffers feature
Date: Mon, 2 Dec 2019 11:47:01 -0500	[thread overview]
Message-ID: <20191202112345-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <BN6PR1801MB20671CCFC812042D5E24D3BCC5430@BN6PR1801MB2067.namprd18.prod.outlook.com>

On Mon, Dec 02, 2019 at 04:16:46PM +0000, Vitaly Mireyno wrote:
> >> >as an example of a vague idea, exposing max rx s/g, min buffer + max
> >> >buffer will allow device to force this from device side.
> >> >
> >> >Is that good? If not, how does driver decide on a good fixed buffer size?
> >> >
> >>
> >> Setting max=min=fixed_size by the device will work, but this seems too
> >restrictive, as we still may want to enable the driver to select its buffer size.
> >> I guess driver can select the fixed buffer size based on the MTU.
> >
> >
> >Would that be based on max MTU field then?
> >I note that that's read-only, so just starting with that and sending it back to the
> >device doesn't change much ...
> >
> 
> I had in mind the actual interface MTU, and not the maximum supported
> MTU (given the device provided one).  Perhaps it's a different
> discussion, but in this sense I find the 'mtu' field a bit confusing.
> Device advertises its maximum supported MTU, but then it's being used
> as an actual MTU (which can be much smaller).

This was sufficient for what it was used for (encapsulation).


> Shouldn't device enforce
> the actual MTU on TX and RX packets?

We need to think of a set of usecases to address though. It's also
tricky wrt things like migration.

>  I also noticed that the spec
> mentions the maximum RX packet size is strictly 1514 bytes (w/o TSO).

It might make sense to extend that for jumbo frames etc. And, I suspect
it doesn't match what drivers/devices actually do in all cases.
Would be great if someone looked at this some more.

> >> What if device will request max/min buffer size ratio, and driver will set min
> >buffer size? This can solve the fixed size issue, without forcing a specific size.
> >> Along with the max s/g, maybe it can also help avoiding rx buffer size abuse
> >by the driver (i.e. setting it too low).
> >
> >That sounds reasonably generic, too.
> >
> 
> Ok, I will formulate a new patch.
> 
> >--
> >MST
> 


This publicly archived list offers a means to provide input to the
OASIS Virtual I/O Device (VIRTIO) TC.

In order to verify user consent to the Feedback License terms and
to minimize spam in the list archive, subscription is required
before posting.

Subscribe: virtio-comment-subscribe@lists.oasis-open.org
Unsubscribe: virtio-comment-unsubscribe@lists.oasis-open.org
List help: virtio-comment-help@lists.oasis-open.org
List archive: https://lists.oasis-open.org/archives/virtio-comment/
Feedback License: https://www.oasis-open.org/who/ipr/feedback_license.pdf
List Guidelines: https://www.oasis-open.org/policies-guidelines/mailing-lists
Committee: https://www.oasis-open.org/committees/virtio/
Join OASIS: https://www.oasis-open.org/join/


      reply	other threads:[~2019-12-02 16:47 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-31 10:46 [virtio-comment] Re: [PATCH] virtio-net: Add equal-sized receive buffers feature Vitaly Mireyno
2019-11-01  4:09 ` Michael S. Tsirkin
2019-11-01  7:22   ` Jason Wang
2019-11-05 18:51     ` Michael S. Tsirkin
2019-11-10 14:13       ` [virtio-comment] RE: [EXT] " Vitaly Mireyno
2019-11-10 15:34         ` [virtio-comment] " Michael S. Tsirkin
2019-11-11 13:58           ` [virtio-comment] " Vitaly Mireyno
2019-11-11 15:05             ` [virtio-comment] " Michael S. Tsirkin
2019-11-14 15:49               ` [virtio-comment] " Vitaly Mireyno
2019-11-20 13:23                 ` [virtio-comment] " Michael S. Tsirkin
2019-11-24 15:02                   ` [virtio-comment] " Vitaly Mireyno
2019-11-24 15:30                     ` [virtio-comment] " Michael S. Tsirkin
2019-11-25  3:31                       ` Jason Wang
2019-11-25  7:33                         ` Michael S. Tsirkin
2019-11-25  8:07                           ` Jason Wang
2019-11-25  8:18                             ` Michael S. Tsirkin
2019-11-25  8:22                               ` Jason Wang
2019-11-25  8:30                                 ` Michael S. Tsirkin
2019-11-25  9:46                                   ` Jason Wang
2019-11-26 17:27                       ` Vitaly Mireyno
2019-11-27 13:51                         ` Michael S. Tsirkin
2019-12-01 10:22                           ` Vitaly Mireyno
2019-12-01 13:07                             ` Michael S. Tsirkin
2019-12-01 21:43                               ` Michael S. Tsirkin
2019-12-02 15:09                                 ` Vitaly Mireyno
2019-12-02 15:23                                   ` Michael S. Tsirkin
2019-12-02 16:16                                     ` Vitaly Mireyno
2019-12-02 16:47                                       ` Michael S. Tsirkin [this message]

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=20191202112345-mutt-send-email-mst@kernel.org \
    --to=mst@redhat.com \
    --cc=jasowang@redhat.com \
    --cc=virtio-comment@lists.oasis-open.org \
    --cc=vmireyno@marvell.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