[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-am
From: |
Benjamin Herrenschmidt |
Subject: |
Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio. |
Date: |
Mon, 12 Aug 2013 19:28:07 +1000 |
On Mon, 2013-08-12 at 17:29 +0930, Rusty Russell wrote:
> virtio data structures are defined as "target endian", which assumes
> that's a fixed value. In fact, that actually means it's
> platform-specific.
>
> Hopefully the OASIS virtio 1.0 spec will fix this. Meanwhile, create
> a hook for little endian ppc.
Ok, sorry if I missed a previous debate on that one but why do you do a
call-out to architecture specific stuff (that is not even inline) on
every access ?
If we consider that virtio byte order is global, can't you make it a
global that is *set* by the architecture rather than *polled* by
virtio ?
We have explicit knowledge of when our endianness change (we get the
hcall or a write to some SPR), we can call virtio *then* to adjust the
endianness rather than having a call-out to the platform on every
access.
Ben.
- [Qemu-devel] [PATCH 0/8] virtio for endian curious guests Take #2, Rusty Russell, 2013/08/12
- [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Rusty Russell, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio.,
Benjamin Herrenschmidt <=
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Peter Maydell, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Benjamin Herrenschmidt, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Peter Maydell, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Benjamin Herrenschmidt, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Peter Maydell, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Benjamin Herrenschmidt, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Peter Maydell, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Anthony Liguori, 2013/08/12
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Rusty Russell, 2013/08/13
- Re: [Qemu-devel] [PATCH 1/8] virtio_get_byteswap: function for endian-ambivalent targets using virtio., Benjamin Herrenschmidt, 2013/08/13