From: Rusty Russell <rusty@rustcorp.com.au>
To: Sasha Levin <levinsasha928@gmail.com>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
linux-kernel <linux-kernel@vger.kernel.org>,
kvm <kvm@vger.kernel.org>,
virtualization <virtualization@lists.linux-foundation.org>,
Anthony Liguori <anthony@codemonkey.ws>
Subject: Re: virtio-pci new configuration proposal
Date: Fri, 04 Nov 2011 20:14:43 +1030 [thread overview]
Message-ID: <87lirwrzlg.fsf@rustcorp.com.au> (raw)
In-Reply-To: <1320309203.29407.1.camel@lappy>
On Thu, 03 Nov 2011 10:33:23 +0200, Sasha Levin <levinsasha928@gmail.com> wrote:
> On Thu, 2011-11-03 at 12:28 +1030, Rusty Russell wrote:
> > 2) I don't think we want to turn the device-specific config into a
> > linked list. We haven't needed variable-length config (yet!), and
> > it's (slightly) more complex. That's also the part of the spec which
> > is shared with non-PCI virtio implementations.
>
> Variable length config wasn't used yet because space in the device
> specific space was reserved for a feature even if that feature wasn't
> used.
>
> For example, the MAC feature reserved 6 bytes in the config space for
> the MAC even if VIRTIO_NET_F_MAC wasn't enabled. Here we can just avoid
> having it pollute the config space until it's enabled.
Exactly. But we haven't had a problem so far; but we don't put
arbitrarily large fields in there.
> I don't think it'll have any impact on non-PCI implementations since the
> "pointers" are simply offsets from the beginning of the config space,
> and are not PCI specific in any way.
But the drivers currently just use offsetof() to access it, eg:
if (virtio_config_val_len(vdev, VIRTIO_NET_F_MAC,
offsetof(struct virtio_net_config, mac),
dev->dev_addr, dev->addr_len) < 0)
That would have to change, and that means a change for drivers and for
the non-PCI implementations.
Hence I think this is a step too far.
> > 3) If we're changing the queue layout, it's a chance to fix a
> > longstanding bug: let the guest notify the host of preferred
> > queue size and alignment.
>
> Yup, we can do that.
The seabios guys will definitely thank you!
Cheers,
Rusty.
next prev parent reply other threads:[~2011-11-04 9:48 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-02 18:49 virtio-pci new configuration proposal Sasha Levin
2011-11-02 19:08 ` Michael S. Tsirkin
2011-11-02 19:07 ` Sasha Levin
2011-11-02 19:14 ` Michael S. Tsirkin
2011-11-03 1:58 ` Rusty Russell
2011-11-03 8:33 ` Sasha Levin
2011-11-03 12:46 ` Michael S. Tsirkin
2011-11-03 13:19 ` Sasha Levin
2011-11-03 13:48 ` Michael S. Tsirkin
2011-11-04 9:44 ` Rusty Russell [this message]
2011-11-04 11:40 ` Michael S. Tsirkin
2011-11-04 12:32 ` Sasha Levin
2011-11-04 13:51 ` Michael S. Tsirkin
2011-11-04 13:53 ` Sasha Levin
2011-11-04 14:23 ` Michael S. Tsirkin
2011-11-04 14:53 ` Sasha Levin
2011-11-06 7:30 ` Michael S. Tsirkin
2011-11-06 20:24 ` Sasha Levin
2011-11-06 21:38 ` Michael S. Tsirkin
2011-11-07 5:16 ` Rusty Russell
2011-11-07 21:14 ` Michael S. Tsirkin
2011-11-07 23:53 ` Rusty Russell
2011-11-08 6:32 ` Michael S. Tsirkin
2011-11-08 10:21 ` Rusty Russell
2011-11-08 21:31 ` Michael S. Tsirkin
2011-11-08 14:15 ` Sasha Levin
2011-11-03 11:03 ` 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=87lirwrzlg.fsf@rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=anthony@codemonkey.ws \
--cc=kvm@vger.kernel.org \
--cc=levinsasha928@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mst@redhat.com \
--cc=virtualization@lists.linux-foundation.org \
/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