Skip to contentSkip to conversation

Question about get the user or kernel mode of vmx vcpu

DISCUSSION Wangbei 2 participants 2 messages Jun 5, 2013

lore
Share & tools
lore

Wangbei

author
#0 lore raw

Hi,
This is Bei Wang, . I am doing research of spinlock optimization to deal with lock holder preemption.
I want to filter vcpu to make precise scheduling.If the vcpu of vmx hvm is running on user mode in guest,it will be filtered out.In linux-kvm ,I use vmx_get_cpl function to get
But now i have a question to migrate the code into xen platform.I can't find any suitable function to judge cpl of vcpu.It seems that vmx_guest_x86_mode(arch/x86/hvm/vmx/vmx.c)don't output the mode of kernel or user in hvm. So what should I do to get the vcpu cpl of vmx in xen? Can you give me some advice?
By the way ,my server is x86 architecture.(DELL T710),not IA64
Thank you very much :)
Wangbei
2013/6/5

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#1 lore raw

On 05/06/13 17:24, Wangbei wrote:

You probably want something based on _get_cpl() from xen/arch/x86/x86_emulate/x86_emulate.c

~Andrew