[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-users] use hypercall in kernel module
While we can use privcmd_call in hypercall.h to issue the hypercall in kernel module, it is unclear how to set the arguments to adapt it to registers. static inline long privcmd_call(unsigned call, Take HYPERCALL_hvm_op as an example, the arguments are op and arg, when the op is HVMOP_altp2m, we need to convert arg to xen_hvm_altp2m_op. Now what if I want to directly assign a xen_hvm_altp2m_op as the argument a2 and HVMOP_altp2m as a1 and __HYPERVISOR_hvm_op as call? How can a2 be assigned as it is defined as a uint64 while xen_hvm_altp2m_op is a structure? Should I use (xen_hvm_altp2m_op *) pointer as a2? Or is there any example on how to use hypercall in LKM (linux loadable kernel module)? I don't know how to convert the arguments to registers. 2016-05-22 20:30 GMT+08:00 Big Strong <fangtuo90@xxxxxxxxx>:
_______________________________________________ Xen-users mailing list Xen-users@xxxxxxxxxxxxx http://lists.xen.org/xen-users
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |