From 14b61778bc968d121dd19c4e960d98c441271a7d Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Mon, 28 Mar 2022 17:58:27 +0200 Subject: [PATCH 1/2] virtio: fix --enable-vhost-user build on non-Linux MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The vhost-shadow-virtqueue.c build requires include files from linux-headers/, so it cannot be built on non-Linux systems. Fortunately it is only needed by vhost-vdpa, so move it there. Acked-by: Eugenio Pérez Acked-by: Jason Wang Signed-off-by: Paolo Bonzini --- hw/virtio/meson.build | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/virtio/meson.build b/hw/virtio/meson.build index 6047670804..67dc77e00f 100644 --- a/hw/virtio/meson.build +++ b/hw/virtio/meson.build @@ -11,9 +11,9 @@ softmmu_ss.add(when: 'CONFIG_ALL', if_true: files('vhost-stub.c')) virtio_ss = ss.source_set() virtio_ss.add(files('virtio.c')) -virtio_ss.add(when: 'CONFIG_VHOST', if_true: files('vhost.c', 'vhost-backend.c', 'vhost-shadow-virtqueue.c', 'vhost-iova-tree.c')) +virtio_ss.add(when: 'CONFIG_VHOST', if_true: files('vhost.c', 'vhost-backend.c', 'vhost-iova-tree.c')) virtio_ss.add(when: 'CONFIG_VHOST_USER', if_true: files('vhost-user.c')) -virtio_ss.add(when: 'CONFIG_VHOST_VDPA', if_true: files('vhost-vdpa.c')) +virtio_ss.add(when: 'CONFIG_VHOST_VDPA', if_true: files('vhost-shadow-virtqueue.c', 'vhost-vdpa.c')) virtio_ss.add(when: 'CONFIG_VIRTIO_BALLOON', if_true: files('virtio-balloon.c')) virtio_ss.add(when: 'CONFIG_VIRTIO_CRYPTO', if_true: files('virtio-crypto.c')) virtio_ss.add(when: ['CONFIG_VIRTIO_CRYPTO', 'CONFIG_VIRTIO_PCI'], if_true: files('virtio-crypto-pci.c')) From 36e38426ff40c9ba86d4e66027f3a98747890623 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Tue, 29 Mar 2022 12:44:39 +0200 Subject: [PATCH 2/2] tests/tcg: really fix path to target configuration MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This was attempted in commit 533b0a1a41 ("tests/tcg: Fix target-specific Makefile variables path for user-mode", 2022-01-12) but it also used the wrong path; default.mak is used for config/devices, not config/targets. While at it, explain what the inclusion is about. Cc: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Paolo Bonzini --- tests/tcg/Makefile.target | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/tcg/Makefile.target b/tests/tcg/Makefile.target index ae8004c76e..acda5bcec2 100644 --- a/tests/tcg/Makefile.target +++ b/tests/tcg/Makefile.target @@ -32,8 +32,10 @@ all: -include ../../../config-host.mak -include ../config-$(TARGET).mak + +# Get semihosting definitions for user-mode emulation ifeq ($(CONFIG_USER_ONLY),y) --include $(SRC_PATH)/configs/targets/$(TARGET)/default.mak +-include $(SRC_PATH)/configs/targets/$(TARGET).mak endif # for including , in command strings