Lines Matching refs:vmcs12

39 static inline struct vmcs12 *get_vmcs12(struct kvm_vcpu *vcpu)  in get_vmcs12()
44 static inline struct vmcs12 *get_shadow_vmcs12(struct kvm_vcpu *vcpu) in get_shadow_vmcs12()
86 static inline unsigned long nested_read_cr0(struct vmcs12 *fields) in nested_read_cr0()
91 static inline unsigned long nested_read_cr4(struct vmcs12 *fields) in nested_read_cr4()
130 static inline bool nested_cpu_has(struct vmcs12 *vmcs12, u32 bit) in nested_cpu_has() argument
132 return vmcs12->cpu_based_vm_exec_control & bit; in nested_cpu_has()
135 static inline bool nested_cpu_has2(struct vmcs12 *vmcs12, u32 bit) in nested_cpu_has2() argument
137 return (vmcs12->cpu_based_vm_exec_control & in nested_cpu_has2()
139 (vmcs12->secondary_vm_exec_control & bit); in nested_cpu_has2()
142 static inline bool nested_cpu_has_preemption_timer(struct vmcs12 *vmcs12) in nested_cpu_has_preemption_timer() argument
144 return vmcs12->pin_based_vm_exec_control & in nested_cpu_has_preemption_timer()
148 static inline bool nested_cpu_has_nmi_exiting(struct vmcs12 *vmcs12) in nested_cpu_has_nmi_exiting() argument
150 return vmcs12->pin_based_vm_exec_control & PIN_BASED_NMI_EXITING; in nested_cpu_has_nmi_exiting()
153 static inline bool nested_cpu_has_virtual_nmis(struct vmcs12 *vmcs12) in nested_cpu_has_virtual_nmis() argument
155 return vmcs12->pin_based_vm_exec_control & PIN_BASED_VIRTUAL_NMIS; in nested_cpu_has_virtual_nmis()
158 static inline int nested_cpu_has_mtf(struct vmcs12 *vmcs12) in nested_cpu_has_mtf() argument
160 return nested_cpu_has(vmcs12, CPU_BASED_MONITOR_TRAP_FLAG); in nested_cpu_has_mtf()
163 static inline int nested_cpu_has_ept(struct vmcs12 *vmcs12) in nested_cpu_has_ept() argument
165 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_ENABLE_EPT); in nested_cpu_has_ept()
168 static inline bool nested_cpu_has_xsaves(struct vmcs12 *vmcs12) in nested_cpu_has_xsaves() argument
170 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_XSAVES); in nested_cpu_has_xsaves()
173 static inline bool nested_cpu_has_pml(struct vmcs12 *vmcs12) in nested_cpu_has_pml() argument
175 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_ENABLE_PML); in nested_cpu_has_pml()
178 static inline bool nested_cpu_has_virt_x2apic_mode(struct vmcs12 *vmcs12) in nested_cpu_has_virt_x2apic_mode() argument
180 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_VIRTUALIZE_X2APIC_MODE); in nested_cpu_has_virt_x2apic_mode()
183 static inline bool nested_cpu_has_vpid(struct vmcs12 *vmcs12) in nested_cpu_has_vpid() argument
185 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_ENABLE_VPID); in nested_cpu_has_vpid()
188 static inline bool nested_cpu_has_apic_reg_virt(struct vmcs12 *vmcs12) in nested_cpu_has_apic_reg_virt() argument
190 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_APIC_REGISTER_VIRT); in nested_cpu_has_apic_reg_virt()
193 static inline bool nested_cpu_has_vid(struct vmcs12 *vmcs12) in nested_cpu_has_vid() argument
195 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_VIRTUAL_INTR_DELIVERY); in nested_cpu_has_vid()
198 static inline bool nested_cpu_has_posted_intr(struct vmcs12 *vmcs12) in nested_cpu_has_posted_intr() argument
200 return vmcs12->pin_based_vm_exec_control & PIN_BASED_POSTED_INTR; in nested_cpu_has_posted_intr()
203 static inline bool nested_cpu_has_vmfunc(struct vmcs12 *vmcs12) in nested_cpu_has_vmfunc() argument
205 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_ENABLE_VMFUNC); in nested_cpu_has_vmfunc()
208 static inline bool nested_cpu_has_eptp_switching(struct vmcs12 *vmcs12) in nested_cpu_has_eptp_switching() argument
210 return nested_cpu_has_vmfunc(vmcs12) && in nested_cpu_has_eptp_switching()
211 (vmcs12->vm_function_control & in nested_cpu_has_eptp_switching()
215 static inline bool nested_cpu_has_shadow_vmcs(struct vmcs12 *vmcs12) in nested_cpu_has_shadow_vmcs() argument
217 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_SHADOW_VMCS); in nested_cpu_has_shadow_vmcs()
220 static inline bool nested_cpu_has_save_preemption_timer(struct vmcs12 *vmcs12) in nested_cpu_has_save_preemption_timer() argument
222 return vmcs12->vm_exit_controls & in nested_cpu_has_save_preemption_timer()
241 static inline bool nested_cpu_has_encls_exit(struct vmcs12 *vmcs12) in nested_cpu_has_encls_exit() argument
243 return nested_cpu_has2(vmcs12, SECONDARY_EXEC_ENCLS_EXITING); in nested_cpu_has_encls_exit()
259 struct vmcs12 *vmcs12 = get_vmcs12(vcpu); in nested_guest_cr0_valid() local
263 nested_cpu_has2(vmcs12, SECONDARY_EXEC_UNRESTRICTED_GUEST)) in nested_guest_cr0_valid()