mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
introduce guest_handle_for_field()
This helper turns a field of a GUEST_HANDLE in a GUEST_HANDLE. Signed-off-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
1 parent
d2f664abe8
commit
bb54458513
1 file changed
+3
@@ -51,6 +51,9 @@
|
||||
(XEN_GUEST_HANDLE(type)) { _x }; \
|
||||
})
|
||||
|
||||
#define guest_handle_for_field(hnd, type, fld) \
|
||||
((XEN_GUEST_HANDLE(type)) { &(hnd).p->fld })
|
||||
|
||||
#define guest_handle_from_ptr(ptr, type) \
|
||||
((XEN_GUEST_HANDLE(type)) { (type *)ptr })
|
||||
#define const_guest_handle_from_ptr(ptr, type) \
|
||||
|
||||