--- /dev/null
+From f7a6df5f5bf3acc219352a1b25573ae2082d7e42 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Thu, 3 Dec 2020 20:58:19 +0100
+Subject: [PATCH] Fix build with 64 bits time_t
+
+time element is deprecated on new input_event structure in kernel's
+input.h [1]
+
+This will avoid the following build failure:
+
+hw/input/virtio-input-host.c: In function 'virtio_input_host_handle_status':
+hw/input/virtio-input-host.c:198:28: error: 'struct input_event' has no member named 'time'
+ 198 | if (gettimeofday(&evdev.time, NULL)) {
+ | ^
+
+Fixes:
+ - http://autobuild.buildroot.org/results/a538167e288c14208d557cd45446df86d3d599d5
+ - http://autobuild.buildroot.org/results/efd4474fb4b6c0ce0ab3838ce130429c51e43bbb
+
+[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit?id=152194fe9c3f
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Message-Id: <20201203195819.583626-1-fontaine.fabrice@gmail.com>
+Fixes: https://gitlab.com/qemu-project/qemu/-/issues/246
+Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
+Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
+
+[Retrieved (and updated for qemu-xen) from:
+https://github.com/qemu/qemu/commit/f7a6df5f5bf3acc219352a1b25573ae2082d7e42]
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ contrib/vhost-user-input/main.c | 8 ++++++--
+ hw/input/virtio-input-host.c | 5 ++++-
+ 2 files changed, 10 insertions(+), 3 deletions(-)
+
+diff --git a/tools/qemu-xen/contrib/vhost-user-input/main.c b/tools/qemu-xen/contrib/vhost-user-input/main.c
+index c15d18c33f0c..081230da548a 100644
+--- a/tools/qemu-xen/contrib/vhost-user-input/main.c
++++ b/tools/qemu-xen/contrib/vhost-user-input/main.c
+@@ -6,13 +6,14 @@
+ #include "qemu/osdep.h"
+
+ #include <glib.h>
+-#include <linux/input.h>
++#include <sys/ioctl.h>
+
+ #include "qemu/iov.h"
+ #include "qemu/bswap.h"
+ #include "qemu/sockets.h"
+ #include "contrib/libvhost-user/libvhost-user.h"
+ #include "contrib/libvhost-user/libvhost-user-glib.h"
++#include "standard-headers/linux/input.h"
+ #include "standard-headers/linux/virtio_input.h"
+ #include "qapi/error.h"
+
+@@ -113,13 +114,16 @@ vi_evdev_watch(VuDev *dev, int condition, void *data)
+ static void vi_handle_status(VuInput *vi, virtio_input_event *event)
+ {
+ struct input_event evdev;
++ struct timeval tval;
+ int rc;
+
+- if (gettimeofday(&evdev.time, NULL)) {
++ if (gettimeofday(&tval, NULL)) {
+ perror("vi_handle_status: gettimeofday");
+ return;
+ }
+
++ evdev.input_event_sec = tval.tv_sec;
++ evdev.input_event_usec = tval.tv_usec;
+ evdev.type = le16toh(event->type);
+ evdev.code = le16toh(event->code);
+ evdev.value = le32toh(event->value);
+diff --git a/tools/qemu-xen/hw/input/virtio-input-host.c b/tools/qemu-xen/hw/input/virtio-input-host.c
+index 85daf73f1a80..137efba57b0f 100644
+--- a/tools/qemu-xen/hw/input/virtio-input-host.c
++++ b/tools/qemu-xen/hw/input/virtio-input-host.c
+@@ -193,13 +193,16 @@ static void virtio_input_host_handle_status(VirtIOInput *vinput,
+ {
+ VirtIOInputHost *vih = VIRTIO_INPUT_HOST(vinput);
+ struct input_event evdev;
++ struct timeval tval;
+ int rc;
+
+- if (gettimeofday(&evdev.time, NULL)) {
++ if (gettimeofday(&tval, NULL)) {
+ perror("virtio_input_host_handle_status: gettimeofday");
+ return;
+ }
+
++ evdev.input_event_sec = tval.tv_sec;
++ evdev.input_event_usec = tval.tv_usec;
+ evdev.type = le16_to_cpu(event->type);
+ evdev.code = le16_to_cpu(event->code);
+ evdev.value = le32_to_cpu(event->value);
+++ /dev/null
-From 5d3e4ebb5c71477d74a0c503438545a0126d3863 Mon Sep 17 00:00:00 2001
-From: Anthony PERARD <anthony.perard@citrix.com>
-Date: Tue, 1 Jun 2021 16:41:47 +0100
-Subject: [PATCH] libs/foreignmemory: Fix osdep_xenforeignmemory_map prototype
-
-Commit cf8c4d3d13b8 made some preparation to have one day
-variable-length-array argument, but didn't declare the array in the
-function prototype the same way as in the function definition. And now
-GCC 11 complains about it.
-
-Fixes: cf8c4d3d13b8 ("tools/libs/foreignmemory: pull array length argument to map forward")
-Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
-Reviewed-by: Jan Beulich <jbeulich@suse.com>
-[Retrieved from:
-https://github.com/xen-project/xen/commit/5d3e4ebb5c71477d74a0c503438545a0126d3863]
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
----
- tools/libs/foreignmemory/private.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tools/libs/foreignmemory/private.h b/tools/libs/foreignmemory/private.h
-index 1ee3626dd278..5bb0cefb0987 100644
---- a/tools/libs/foreignmemory/private.h
-+++ b/tools/libs/foreignmemory/private.h
-@@ -32,7 +32,7 @@ int osdep_xenforeignmemory_close(xenforeignmemory_handle *fmem);
- void *osdep_xenforeignmemory_map(xenforeignmemory_handle *fmem,
- uint32_t dom, void *addr,
- int prot, int flags, size_t num,
-- const xen_pfn_t arr[num], int err[num]);
-+ const xen_pfn_t arr[/*num*/], int err[/*num*/]);
- int osdep_xenforeignmemory_unmap(xenforeignmemory_handle *fmem,
- void *addr, size_t num);
-
+++ /dev/null
-From f7a6df5f5bf3acc219352a1b25573ae2082d7e42 Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Thu, 3 Dec 2020 20:58:19 +0100
-Subject: [PATCH] Fix build with 64 bits time_t
-
-time element is deprecated on new input_event structure in kernel's
-input.h [1]
-
-This will avoid the following build failure:
-
-hw/input/virtio-input-host.c: In function 'virtio_input_host_handle_status':
-hw/input/virtio-input-host.c:198:28: error: 'struct input_event' has no member named 'time'
- 198 | if (gettimeofday(&evdev.time, NULL)) {
- | ^
-
-Fixes:
- - http://autobuild.buildroot.org/results/a538167e288c14208d557cd45446df86d3d599d5
- - http://autobuild.buildroot.org/results/efd4474fb4b6c0ce0ab3838ce130429c51e43bbb
-
-[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit?id=152194fe9c3f
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Message-Id: <20201203195819.583626-1-fontaine.fabrice@gmail.com>
-Fixes: https://gitlab.com/qemu-project/qemu/-/issues/246
-Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
-
-[Retrieved (and updated for qemu-xen) from:
-https://github.com/qemu/qemu/commit/f7a6df5f5bf3acc219352a1b25573ae2082d7e42]
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
----
- contrib/vhost-user-input/main.c | 8 ++++++--
- hw/input/virtio-input-host.c | 5 ++++-
- 2 files changed, 10 insertions(+), 3 deletions(-)
-
-diff --git a/tools/qemu-xen/contrib/vhost-user-input/main.c b/tools/qemu-xen/contrib/vhost-user-input/main.c
-index c15d18c33f0c..081230da548a 100644
---- a/tools/qemu-xen/contrib/vhost-user-input/main.c
-+++ b/tools/qemu-xen/contrib/vhost-user-input/main.c
-@@ -6,13 +6,14 @@
- #include "qemu/osdep.h"
-
- #include <glib.h>
--#include <linux/input.h>
-+#include <sys/ioctl.h>
-
- #include "qemu/iov.h"
- #include "qemu/bswap.h"
- #include "qemu/sockets.h"
- #include "contrib/libvhost-user/libvhost-user.h"
- #include "contrib/libvhost-user/libvhost-user-glib.h"
-+#include "standard-headers/linux/input.h"
- #include "standard-headers/linux/virtio_input.h"
- #include "qapi/error.h"
-
-@@ -113,13 +114,16 @@ vi_evdev_watch(VuDev *dev, int condition, void *data)
- static void vi_handle_status(VuInput *vi, virtio_input_event *event)
- {
- struct input_event evdev;
-+ struct timeval tval;
- int rc;
-
-- if (gettimeofday(&evdev.time, NULL)) {
-+ if (gettimeofday(&tval, NULL)) {
- perror("vi_handle_status: gettimeofday");
- return;
- }
-
-+ evdev.input_event_sec = tval.tv_sec;
-+ evdev.input_event_usec = tval.tv_usec;
- evdev.type = le16toh(event->type);
- evdev.code = le16toh(event->code);
- evdev.value = le32toh(event->value);
-diff --git a/tools/qemu-xen/hw/input/virtio-input-host.c b/tools/qemu-xen/hw/input/virtio-input-host.c
-index 85daf73f1a80..137efba57b0f 100644
---- a/tools/qemu-xen/hw/input/virtio-input-host.c
-+++ b/tools/qemu-xen/hw/input/virtio-input-host.c
-@@ -193,13 +193,16 @@ static void virtio_input_host_handle_status(VirtIOInput *vinput,
- {
- VirtIOInputHost *vih = VIRTIO_INPUT_HOST(vinput);
- struct input_event evdev;
-+ struct timeval tval;
- int rc;
-
-- if (gettimeofday(&evdev.time, NULL)) {
-+ if (gettimeofday(&tval, NULL)) {
- perror("virtio_input_host_handle_status: gettimeofday");
- return;
- }
-
-+ evdev.input_event_sec = tval.tv_sec;
-+ evdev.input_event_usec = tval.tv_usec;
- evdev.type = le16_to_cpu(event->type);
- evdev.code = le16_to_cpu(event->code);
- evdev.value = le32_to_cpu(event->value);
--- /dev/null
+From a8ac01aa3e3ea5e6a9a1620aa8fa7e9da3458120 Mon Sep 17 00:00:00 2001
+From: Manuel Bouyer <bouyer@netbsd.org>
+Date: Tue, 26 Jan 2021 23:47:55 +0100
+Subject: [PATCH] libs/light: fix tv_sec printf format
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Don't assume tv_sec is a unsigned long, it is 64 bits on NetBSD 32 bits.
+Use %jd and cast to (intmax_t) instead
+
+Signed-off-by: Manuel Bouyer <bouyer@netbsd.org>
+Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
+[Retrieved (and backported) from:
+https://gitlab.com/xen-project/xen/-/commit/a8ac01aa3e3ea5e6a9a1620aa8fa7e9da3458120]
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ tools/libs/light/libxl_create.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/tools/libxl/libxl_create.c b/tools/libxl/libxl_create.c
+index 8616113e72..9848d65f36 100644
+--- a/tools/libxl/libxl_create.c
++++ b/tools/libxl/libxl_create.c
+@@ -496,7 +496,7 @@ int libxl__domain_build(libxl__gc *gc,
+ vments[2] = "image/ostype";
+ vments[3] = "hvm";
+ vments[4] = "start_time";
+- vments[5] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
++ vments[5] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
+
+ localents = libxl__calloc(gc, 13, sizeof(char *));
+ i = 0;
+@@ -535,7 +535,7 @@ int libxl__domain_build(libxl__gc *gc,
+ vments[i++] = "image/kernel";
+ vments[i++] = (char *) state->pv_kernel.path;
+ vments[i++] = "start_time";
+- vments[i++] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
++ vments[i++] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
+ if (state->pv_ramdisk.path) {
+ vments[i++] = "image/ramdisk";
+ vments[i++] = (char *) state->pv_ramdisk.path;
+@@ -1502,7 +1502,7 @@ static void domcreate_stream_done(libxl__egc *egc,
+ vments[2] = "image/ostype";
+ vments[3] = "hvm";
+ vments[4] = "start_time";
+- vments[5] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
++ vments[5] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
+ break;
+ case LIBXL_DOMAIN_TYPE_PV:
+ vments = libxl__calloc(gc, 11, sizeof(char *));
+@@ -1512,7 +1512,7 @@ static void domcreate_stream_done(libxl__egc *egc,
+ vments[i++] = "image/kernel";
+ vments[i++] = (char *) state->pv_kernel.path;
+ vments[i++] = "start_time";
+- vments[i++] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
++ vments[i++] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
+ if (state->pv_ramdisk.path) {
+ vments[i++] = "image/ramdisk";
+ vments[i++] = (char *) state->pv_ramdisk.path;
+--
+GitLab
+
--- /dev/null
+From 4881285bcfd8f2e2c913c6e9f011b1e90652f414 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Sat, 28 Aug 2021 11:00:07 +0200
+Subject: [PATCH] libs/light: fix tv_sec fprintf format
+
+Don't assume tv_sec is a unsigned long, it is 64 bits on NetBSD 32 bits.
+Use %jd and cast to (intmax_t) instead
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Upstream status: sent to xen-devel@lists.xenproject.org]
+---
+ tools/libs/light/libxl_domain.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tools/libxl/libxl_domain.c b/tools/libxl/libxl_domain.c
+index c00c36c928..51a6127552 100644
+--- a/tools/libxl/libxl_domain.c
++++ b/tools/libxl/libxl_domain.c
+@@ -1444,7 +1444,7 @@ static int libxl__mark_domid_recent(libxl__gc *gc, uint32_t domid)
+ }
+ }
+
+- r = fprintf(nf, "%lu %u\n", ctxt.ts.tv_sec, domid);
++ r = fprintf(nf, "%jd %u\n", (intmax_t)ctxt.ts.tv_sec, domid);
+ if (r < 0) {
+ LOGED(ERROR, domid, "failed to write to '%s'", new);
+ goto out;
+--
+2.32.0
+
+++ /dev/null
-From a8ac01aa3e3ea5e6a9a1620aa8fa7e9da3458120 Mon Sep 17 00:00:00 2001
-From: Manuel Bouyer <bouyer@netbsd.org>
-Date: Tue, 26 Jan 2021 23:47:55 +0100
-Subject: [PATCH] libs/light: fix tv_sec printf format
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Don't assume tv_sec is a unsigned long, it is 64 bits on NetBSD 32 bits.
-Use %jd and cast to (intmax_t) instead
-
-Signed-off-by: Manuel Bouyer <bouyer@netbsd.org>
-Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
-[Retrieved (and backported) from:
-https://gitlab.com/xen-project/xen/-/commit/a8ac01aa3e3ea5e6a9a1620aa8fa7e9da3458120]
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
----
- tools/libs/light/libxl_create.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/tools/libxl/libxl_create.c b/tools/libxl/libxl_create.c
-index 8616113e72..9848d65f36 100644
---- a/tools/libxl/libxl_create.c
-+++ b/tools/libxl/libxl_create.c
-@@ -496,7 +496,7 @@ int libxl__domain_build(libxl__gc *gc,
- vments[2] = "image/ostype";
- vments[3] = "hvm";
- vments[4] = "start_time";
-- vments[5] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
-+ vments[5] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
-
- localents = libxl__calloc(gc, 13, sizeof(char *));
- i = 0;
-@@ -535,7 +535,7 @@ int libxl__domain_build(libxl__gc *gc,
- vments[i++] = "image/kernel";
- vments[i++] = (char *) state->pv_kernel.path;
- vments[i++] = "start_time";
-- vments[i++] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
-+ vments[i++] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
- if (state->pv_ramdisk.path) {
- vments[i++] = "image/ramdisk";
- vments[i++] = (char *) state->pv_ramdisk.path;
-@@ -1502,7 +1502,7 @@ static void domcreate_stream_done(libxl__egc *egc,
- vments[2] = "image/ostype";
- vments[3] = "hvm";
- vments[4] = "start_time";
-- vments[5] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
-+ vments[5] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
- break;
- case LIBXL_DOMAIN_TYPE_PV:
- vments = libxl__calloc(gc, 11, sizeof(char *));
-@@ -1512,7 +1512,7 @@ static void domcreate_stream_done(libxl__egc *egc,
- vments[i++] = "image/kernel";
- vments[i++] = (char *) state->pv_kernel.path;
- vments[i++] = "start_time";
-- vments[i++] = GCSPRINTF("%lu.%02d", start_time.tv_sec,(int)start_time.tv_usec/10000);
-+ vments[i++] = GCSPRINTF("%jd.%02d", (intmax_t)start_time.tv_sec,(int)start_time.tv_usec/10000);
- if (state->pv_ramdisk.path) {
- vments[i++] = "image/ramdisk";
- vments[i++] = (char *) state->pv_ramdisk.path;
---
-GitLab
-
+++ /dev/null
-From 4881285bcfd8f2e2c913c6e9f011b1e90652f414 Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Sat, 28 Aug 2021 11:00:07 +0200
-Subject: [PATCH] libs/light: fix tv_sec fprintf format
-
-Don't assume tv_sec is a unsigned long, it is 64 bits on NetBSD 32 bits.
-Use %jd and cast to (intmax_t) instead
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-[Upstream status: sent to xen-devel@lists.xenproject.org]
----
- tools/libs/light/libxl_domain.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tools/libxl/libxl_domain.c b/tools/libxl/libxl_domain.c
-index c00c36c928..51a6127552 100644
---- a/tools/libxl/libxl_domain.c
-+++ b/tools/libxl/libxl_domain.c
-@@ -1444,7 +1444,7 @@ static int libxl__mark_domid_recent(libxl__gc *gc, uint32_t domid)
- }
- }
-
-- r = fprintf(nf, "%lu %u\n", ctxt.ts.tv_sec, domid);
-+ r = fprintf(nf, "%jd %u\n", (intmax_t)ctxt.ts.tv_sec, domid);
- if (r < 0) {
- LOGED(ERROR, domid, "failed to write to '%s'", new);
- goto out;
---
-2.32.0
-
# Locally computed
-sha256 e35099a963070e3c9f425d1e36cbb1c40b7874ef449bfafd6688343783cb25ad xen-4.14.2.tar.gz
+sha256 a3dad76a772393a1875e8f44a6059a95fea4bde40f97b800966969ac6f3a498d xen-4.14.3.tar.gz
sha256 ecca9538e9d3f7e3c2bff827502f4495e2ef9e22c451298696ea08886b176c2c COPYING
#
################################################################################
-XEN_VERSION = 4.14.2
+XEN_VERSION = 4.14.3
XEN_SITE = https://downloads.xenproject.org/release/xen/$(XEN_VERSION)
XEN_LICENSE = GPL-2.0
XEN_LICENSE_FILES = COPYING