x86/dmop: Fix compat_dm_op() ABI

The parameter to compat_dm_op() is a pointer to an array of
compat_dm_op_buf_t's in guest RAM.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
Andrew Cooper committed 2017-02-01 16:50:39 +00:00
1 parent ad5808d905
commit 8844ed299a
2 files changed
+3 -3

No files matched your search

+2 -2
View File
@@ -525,7 +525,7 @@ CHECK_dm_op_inject_msi;
int compat_dm_op(domid_t domid,
unsigned int nr_bufs,
COMPAT_HANDLE_PARAM(compat_dm_op_buf_t) bufs)
XEN_GUEST_HANDLE_PARAM(void) bufs)
{
struct xen_dm_op_buf nat[MAX_NR_BUFS];
unsigned int i;
@@ -538,7 +538,7 @@ int compat_dm_op(domid_t domid,
{
struct compat_dm_op_buf cmp;
if ( copy_from_compat_offset(&cmp, bufs, i, 1) )
if ( copy_from_guest_offset(&cmp, bufs, i, 1) )
return -EFAULT;
#define XLAT_dm_op_buf_HNDL_h(_d_, _s_) \
+1 -1
View File
@@ -203,7 +203,7 @@ extern int
compat_dm_op(
domid_t domid,
unsigned int nr_bufs,
COMPAT_HANDLE_PARAM(compat_dm_op_buf_t) bufs);
XEN_GUEST_HANDLE_PARAM(void) bufs);
#endif
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.