qemu-devel
[Top][All Lists]
Advanced

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

[RFC 4/4] HACK: Hard-code the libvhost-user.o-cflags for s390x


From: Marc Hartmayer
Subject: [RFC 4/4] HACK: Hard-code the libvhost-user.o-cflags for s390x
Date: Thu, 25 Jun 2020 12:04:30 +0200

This patch exists only to show the actual problem that libvhost-user
and it's users are architecture dependent as soon as we're trying to
support legacy virtio.

Signed-off-by: Marc Hartmayer <mhartmay@linux.ibm.com>
---
 Makefile.objs                           | 1 +
 contrib/libvhost-user/libvhost-access.h | 7 +++----
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/Makefile.objs b/Makefile.objs
index 7ce2588b89a3..abfb1912e456 100644
--- a/Makefile.objs
+++ b/Makefile.objs
@@ -111,6 +111,7 @@ elf2dmp-obj-y = contrib/elf2dmp/
 ivshmem-client-obj-$(CONFIG_IVSHMEM) = contrib/ivshmem-client/
 ivshmem-server-obj-$(CONFIG_IVSHMEM) = contrib/ivshmem-server/
 libvhost-user-obj-y = contrib/libvhost-user/
+libvhost-user.o-cflags += -iquote $(SRC_PATH)/s390x-softmmu -DNEED_CPU_H
 vhost-user-scsi.o-cflags := $(LIBISCSI_CFLAGS)
 vhost-user-scsi.o-libs := $(LIBISCSI_LIBS)
 vhost-user-scsi-obj-y = contrib/vhost-user-scsi/
diff --git a/contrib/libvhost-user/libvhost-access.h 
b/contrib/libvhost-user/libvhost-access.h
index a4fc334fe134..e9451ae0fbc6 100644
--- a/contrib/libvhost-user/libvhost-access.h
+++ b/contrib/libvhost-user/libvhost-access.h
@@ -5,10 +5,9 @@
 
 #include "libvhost-user.h"
 
-/* TODO attempt to use poisoned TARGET_PPC64/ARM */
-/* #if defined(TARGET_PPC64) || defined(TARGET_ARM) */
-/* #define LEGACY_VIRTIO_IS_BIENDIAN 1 */
-/* #endif */
+#if defined(TARGET_PPC64) || defined(TARGET_ARM)
+#define LEGACY_VIRTIO_IS_BIENDIAN 1
+#endif
 
 static inline bool vu_is_big_endian(VuDev *dev)
 {
-- 
2.25.4




reply via email to

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