__guest_handle_param is used to represent a guest pointer stored pass as
an hypercall parameters. They are the same size as the native register
for the architecture. It will be 32-bit on ARM32 and 64-bit on ARM64.

As the __guest_handle_param will always be the size of a native
pointer, there is no need to have a union with an unsigned long.

Note that unsigned long may be not equivalent to the size of a pointer
on ARM64. It depends whether the software is build using the LP64 or
LLP64 data model. The size of an unsigned long in the latter will be
32-bit.

Signed-off-by: Julien Grall <julien.gr...@citrix.com>

---

Cc: Ian Jackson <ian.jack...@eu.citrix.com>
Cc: Jan Beulich <jbeul...@suse.com>
Cc: Keir Fraser <k...@xen.org>
Cc: Tim Deegan <t...@xen.org>
---
 xen/include/public/arch-arm.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/include/public/arch-arm.h b/xen/include/public/arch-arm.h
index 35839db..477254f 100644
--- a/xen/include/public/arch-arm.h
+++ b/xen/include/public/arch-arm.h
@@ -170,7 +170,7 @@
 
 #ifndef __ASSEMBLY__
 #define ___DEFINE_XEN_GUEST_HANDLE(name, type)                  \
-    typedef union { type *p; unsigned long q; }                 \
+    typedef struct { type *p; }                                 \
         __guest_handle_param_ ## name;                          \
     typedef union { type *p; uint64_aligned_t q; }              \
         __guest_handle_ ## name;
-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

Reply via email to