From d047f9926546e177c41a78e299cbe9339fca335f Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Fri, 8 Dec 2023 09:09:11 +0000 Subject: [PATCH] Add patch to fix Xen build See: https://lists.gnu.org/archive/html/qemu-devel/2023-12/msg01035.html --- 0001-fix-qemu-build-with-xen-4.18.0.patch | 26 +++++++++++++++++++++++ qemu.spec | 3 +++ 2 files changed, 29 insertions(+) create mode 100644 0001-fix-qemu-build-with-xen-4.18.0.patch diff --git a/0001-fix-qemu-build-with-xen-4.18.0.patch b/0001-fix-qemu-build-with-xen-4.18.0.patch new file mode 100644 index 0000000..ec716ac --- /dev/null +++ b/0001-fix-qemu-build-with-xen-4.18.0.patch @@ -0,0 +1,26 @@ +From 3a2e5ecdde13bc4eb7f173f6cb36b1a6c752aa1f Mon Sep 17 00:00:00 2001 +Message-ID: <3a2e5ecdde13bc4eb7f173f6cb36b1a6c752aa1f.1701978796.git.m.a.young@durham.ac.uk> +From: Michael Young +Date: Thu, 7 Dec 2023 19:49:20 +0000 +Subject: [PATCH] fix qemu build with xen-4.18.0 + +--- + include/hw/xen/xen_native.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/include/hw/xen/xen_native.h b/include/hw/xen/xen_native.h +index 6f09c48823..04b1ef4d34 100644 +--- a/include/hw/xen/xen_native.h ++++ b/include/hw/xen/xen_native.h +@@ -532,7 +532,7 @@ static inline int xendevicemodel_set_irq_level(xendevicemodel_handle *dmod, + } + #endif + +-#if CONFIG_XEN_CTRL_INTERFACE_VERSION <= 41700 ++#if CONFIG_XEN_CTRL_INTERFACE_VERSION >= 41700 + #define GUEST_VIRTIO_MMIO_BASE xen_mk_ullong(0x02000000) + #define GUEST_VIRTIO_MMIO_SIZE xen_mk_ullong(0x00100000) + #define GUEST_VIRTIO_MMIO_SPI_FIRST 33 +-- +2.43.0 + diff --git a/qemu.spec b/qemu.spec index b14785b..326ffa7 100644 --- a/qemu.spec +++ b/qemu.spec @@ -373,6 +373,9 @@ Source0: https://download.qemu.org/%{name}-%{version}%{?rcstr}.tar.xz # Fix pvh.img ld build failure on fedora rawhide Patch: 0001-pc-bios-optionrom-Fix-pvh.img-ld-build-failure-on-fe.patch +# See https://lists.gnu.org/archive/html/qemu-devel/2023-12/msg01035.html +Patch: 0001-fix-qemu-build-with-xen-4.18.0.patch + Source10: qemu-guest-agent.service Source11: 99-qemu-guest-agent.rules Source12: bridge.conf