xen/privcmd: Add IOCTL_PRIVCMD_DM_OP
Quoted 26 lines · Boris Ostrovsky
Quoted 26 lines
drivers/xen/privcmd.c +2
-0@@ -22,6 +22,7 @@#include <linux/pagemap.h> #include <linux/seq_file.h> #include <linux/miscdevice.h> +#include <linux/moduleparam.h> #include <asm/pgalloc.h> #include <asm/pgtable.h> @@ -32,6 +33,7 @@#include <xen/xen.h> #include <xen/privcmd.h> #include <xen/interface/xen.h> +#include <xen/interface/hvm/dm_op.h> #include <xen/features.h> #include <xen/page.h> #include <xen/xen-ops.h> @@ -43,6 +45,17 @@ MODULE_LICENSE("GPL");#define PRIV_VMA_LOCKED ((void *)1)
Quoted 7 lines
drivers/xen/privcmd.c MODULE_LICENSE("GPL"); · line 53
Quoted 6 lines
drivers/xen/privcmd.c +6
-0+unsigned int privcmd_dm_op_max_num =16 ; +module_param_named (dm_op_max_nr_bufs, privcmd_dm_op_max_num, uint,0644 ); +MODULE_PARM_DESC (dm_op_max_nr_bufs, +"Maximum number of buffers per dm_op hypercall" ); + +unsigned int privcmd_dm_op_buf_max_size =XEN_PAGE_SIZE ;These need to be static. (I can fix it when committing.)
OK. Thanks.
Quoted 5 lines
And I am still not sure about using
XEN_PAGE_SIZE. There is no dependency in the hypervisor on buffers being page-sized, is there? If not,XEN_PAGE_SIZEis here just because it happens to be 4K, which is a reasonable value.
How about just setting it to 4096?
I chose XEN_PAGE_SIZE because the hypercall will eventually copy in the buffer so it seemed like a reasonable value to use. If you want to just use 4096 then I am ok with that.
Paul
Quoted 2 lines
-boris
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel