From: "Michael S. Tsirkin" <mst@redhat.com>
To: Greg Kurz <gkurz@linux.vnet.ibm.com>
Cc: linux-api@vger.kernel.org, linux-kernel@vger.kernel.org,
kvm@vger.kernel.org, virtualization@lists.linux-foundation.org
Subject: Re: [PATCH v2 0/7] vhost: support for cross endian guests
Date: Thu, 2 Apr 2015 16:23:23 +0200 [thread overview]
Message-ID: <20150402162120-mutt-send-email-mst@redhat.com> (raw)
In-Reply-To: <20150402131637.24676.60700.stgit@bahia.lab.toulouse-stg.fr.ibm.com>
On Thu, Apr 02, 2015 at 03:16:37PM +0200, Greg Kurz wrote:
> Hi,
>
> This patchset allows vhost to be used with legacy virtio when guest and host
> have a different endianness. It is a complete rework of my initial post.
>
> Patches 1 to 5 are preliminary work: we move the endianness check out of all
> memory accessors to separate functions.
>
> Patch 6 changes the semantics of the accessors so that they have explicit big
> endian support.
>
> Patch 7 brings the cross-endian feature, with the following changes since v1:
> - conditionnal enablement through a kernel config
> - introduction of a new vhost feature to advertise cross-endian to userspace
I think adding ioctls is sufficient for this, we don't need to burn up a
feature bit.
> The tentative to fix vnet headers was dropped for the moment. As a consequnce,
> vhost_net still fails to work with cross-endian. It will be fixed in another
> patchset I'm currently working on.
I think I'll probably hold off on applying this
patchset until it all actually works.
> ---
>
> Greg Kurz (7):
> virtio: introduce virtio_is_little_endian() helper
> tun: add tun_is_little_endian() helper
> macvtap: introduce macvtap_is_little_endian() helper
> vringh: introduce vringh_is_little_endian() helper
> vhost: introduce vhost_is_little_endian() helper
> virtio: add explicit big-endian support to memory accessors
> vhost: feature to set the vring endianness
>
>
> drivers/net/macvtap.c | 11 +++++++++--
> drivers/net/tun.c | 11 +++++++++--
> drivers/vhost/Kconfig | 10 ++++++++++
> drivers/vhost/net.c | 5 +++++
> drivers/vhost/scsi.c | 4 ++++
> drivers/vhost/test.c | 4 ++++
> drivers/vhost/vhost.c | 19 +++++++++++++++++++
> drivers/vhost/vhost.h | 32 +++++++++++++++++++++++++-------
> include/linux/virtio_byteorder.h | 24 ++++++++++++++----------
> include/linux/virtio_config.h | 19 +++++++++++++------
> include/linux/vringh.h | 19 +++++++++++++------
> include/uapi/linux/vhost.h | 10 ++++++++++
> 12 files changed, 135 insertions(+), 33 deletions(-)
>
> --
> Greg
prev parent reply other threads:[~2015-04-02 14:23 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-02 13:16 [PATCH v2 0/7] vhost: support for cross endian guests Greg Kurz
2015-04-02 13:16 ` [PATCH v2 1/7] virtio: introduce virtio_is_little_endian() helper Greg Kurz
2015-04-02 13:16 ` [PATCH v2 2/7] tun: add tun_is_little_endian() helper Greg Kurz
2015-04-02 13:16 ` [PATCH v2 3/7] macvtap: introduce macvtap_is_little_endian() helper Greg Kurz
2015-04-02 13:16 ` [PATCH v2 4/7] vringh: introduce vringh_is_little_endian() helper Greg Kurz
2015-04-02 13:17 ` [PATCH v2 5/7] vhost: introduce vhost_is_little_endian() helper Greg Kurz
2015-04-02 13:17 ` [PATCH v2 6/7] virtio: add explicit big-endian support to memory accessors Greg Kurz
2015-04-02 13:17 ` [PATCH v2 7/7] vhost: feature to set the vring endianness Greg Kurz
[not found] ` <20150402131713.24676.9924.stgit@bahia.lab.toulouse-stg.fr.ibm.com>
2015-04-02 14:20 ` Michael S. Tsirkin
2015-04-02 16:45 ` Greg Kurz
2015-04-02 18:53 ` Michael S. Tsirkin
2015-04-02 14:23 ` 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=20150402162120-mutt-send-email-mst@redhat.com \
--to=mst@redhat.com \
--cc=gkurz@linux.vnet.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=linux-api@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--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;
as well as URLs for NNTP newsgroup(s).