mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 23:33:54 -06:00
hw/xen: Implement GNTTABOP_query_size
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk> Reviewed-by: Paul Durrant <paul@xen.org>
This commit is contained in:
parent
28b7ae94a2
commit
b46f9745b1
3 changed files with 36 additions and 1 deletions
|
@ -1207,7 +1207,21 @@ static bool kvm_xen_hcall_gnttab_op(struct kvm_xen_exit *exit, X86CPU *cpu,
|
|||
}
|
||||
break;
|
||||
}
|
||||
case GNTTABOP_query_size:
|
||||
case GNTTABOP_query_size: {
|
||||
struct gnttab_query_size size;
|
||||
|
||||
qemu_build_assert(sizeof(size) == 16);
|
||||
if (kvm_copy_from_gva(cs, arg, &size, sizeof(size))) {
|
||||
err = -EFAULT;
|
||||
break;
|
||||
}
|
||||
|
||||
err = xen_gnttab_query_size_op(&size);
|
||||
if (!err && kvm_copy_to_gva(cs, arg, &size, sizeof(size))) {
|
||||
err = -EFAULT;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case GNTTABOP_setup_table:
|
||||
case GNTTABOP_copy:
|
||||
case GNTTABOP_map_grant_ref:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue