qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 0/2] dataplane: use endian-aware memory accessors


From: Stefan Hajnoczi
Subject: [Qemu-devel] [PATCH 0/2] dataplane: use endian-aware memory accessors
Date: Mon, 19 Jan 2015 17:04:35 +0000

In commit 0f5d1d2a49778863db54b4b1ac2dc008a8f21f11 ("virtio: memory accessors
for endian-ambivalent targets") endian-aware memory accessors were added to
support bi-endian targets like recent ppc64 systems.

The dataplane vring.c code does not use these accessors and is therefore unable
to emulate virtio devices when the endianness differs between the device and
host.

These patches modify vring.c to use the endian-aware accessors.

I have tested that x86_64 guests still function correctly.

I have only compile-tested on ppc64 and require help testing that dataplane
works.  If you have access to a bi-endian system, please try:

  qemu ... -object iothread,id=iothread0 \
           -drive if=none,id=drive0,file=... \
           -device virtio-blk-pci,iothread=iothread0,drive=drive0

Stefan Hajnoczi (2):
  dataplane: move vring_more_avail() into vring.c
  dataplane: use virtio_ld/st_p() for endian-aware memory access

 hw/block/dataplane/virtio-blk.c     |  2 +-
 hw/scsi/virtio-scsi-dataplane.c     |  2 +-
 hw/virtio/Makefile.objs             |  2 +-
 hw/virtio/dataplane/Makefile.objs   |  2 +-
 hw/virtio/dataplane/vring.c         | 69 ++++++++++++++++++++++++++-----------
 include/hw/virtio/dataplane/vring.h |  9 ++---
 6 files changed, 55 insertions(+), 31 deletions(-)

-- 
2.1.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]