Commit 1293b5a6f7 for qemu.org
commit 1293b5a6f75ac17bca8fac76daf48aa73829dc7c
Author: Peter Xu <peterx@redhat.com>
Date: Tue Aug 18 13:20:07 2026 -0400
xen-mapcache: Remove 32bit support
QEMU has switched to 64bit-only hosts for all system emulations.
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Link: https://lore.kernel.org/r/20260818172012.3052821-5-peterx@redhat.com
Cc: Stefano Stabellini <sstabellini@kernel.org>
Cc: Anthony PERARD <anthony@xenproject.org>
Cc: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
Cc: xen-devel@lists.xenproject.org
Signed-off-by: Peter Xu <peterx@redhat.com>
diff --git a/hw/xen/xen-mapcache.c b/hw/xen/xen-mapcache.c
index 85cf0cf359..e30c07c2ee 100644
--- a/hw/xen/xen-mapcache.c
+++ b/hw/xen/xen-mapcache.c
@@ -26,11 +26,7 @@
#include <xenevtchn.h>
#include <xengnttab.h>
-#if HOST_LONG_BITS == 32
-# define MCACHE_MAX_SIZE (1UL<<31) /* 2GB Cap */
-#else
-# define MCACHE_MAX_SIZE (1UL<<35) /* 32GB Cap */
-#endif
+#define MCACHE_MAX_SIZE (1UL << 35) /* 32GB Cap */
/* This is the size of the virtual address space reserve to QEMU that will not
* be use by MapCache.
@@ -151,11 +147,7 @@ void xen_map_cache_init(phys_offset_to_gaddr_t f, void *opaque)
exit(EXIT_FAILURE);
}
- if (HOST_LONG_BITS == 32) {
- bucket_shift = 16;
- } else {
- bucket_shift = 20;
- }
+ bucket_shift = 20;
if (geteuid() == 0) {
rlimit_as.rlim_cur = RLIM_INFINITY;