Lines Matching refs:CC

28 #define CC KVM_NESTED_VMENTER_CONSISTENCY_CHECK  macro
529 if (CC(!page_address_valid(vcpu, vmcs12->io_bitmap_a)) || in nested_vmx_check_io_bitmap_controls()
530 CC(!page_address_valid(vcpu, vmcs12->io_bitmap_b))) in nested_vmx_check_io_bitmap_controls()
542 if (CC(!page_address_valid(vcpu, vmcs12->msr_bitmap))) in nested_vmx_check_msr_bitmap_controls()
554 if (CC(!page_address_valid(vcpu, vmcs12->virtual_apic_page_addr))) in nested_vmx_check_tpr_shadow_controls()
776 CC(!page_address_valid(vcpu, vmcs12->apic_access_addr))) in nested_vmx_check_apic_access_controls()
795 if (CC(nested_cpu_has_virt_x2apic_mode(vmcs12) && in nested_vmx_check_apicv_controls()
803 if (CC(nested_cpu_has_vid(vmcs12) && !nested_exit_on_intr(vcpu))) in nested_vmx_check_apicv_controls()
814 (CC(!nested_cpu_has_vid(vmcs12)) || in nested_vmx_check_apicv_controls()
815 CC(!nested_exit_intr_ack_set(vcpu)) || in nested_vmx_check_apicv_controls()
816 CC((vmcs12->posted_intr_nv & 0xff00)) || in nested_vmx_check_apicv_controls()
817 CC(!kvm_vcpu_is_legal_aligned_gpa(vcpu, vmcs12->posted_intr_desc_addr, 64)))) in nested_vmx_check_apicv_controls()
821 if (CC(!nested_cpu_has(vmcs12, CPU_BASED_TPR_SHADOW))) in nested_vmx_check_apicv_controls()
843 if (CC(nested_vmx_check_msr_switch(vcpu, in nested_vmx_check_exit_msr_switch_controls()
846 CC(nested_vmx_check_msr_switch(vcpu, in nested_vmx_check_exit_msr_switch_controls()
857 if (CC(nested_vmx_check_msr_switch(vcpu, in nested_vmx_check_entry_msr_switch_controls()
871 if (CC(!nested_cpu_has_ept(vmcs12)) || in nested_vmx_check_pml_controls()
872 CC(!page_address_valid(vcpu, vmcs12->pml_address))) in nested_vmx_check_pml_controls()
881 if (CC(nested_cpu_has2(vmcs12, SECONDARY_EXEC_UNRESTRICTED_GUEST) && in nested_vmx_check_unrestricted_guest_controls()
890 if (CC(nested_cpu_has2(vmcs12, SECONDARY_EXEC_MODE_BASED_EPT_EXEC) && in nested_vmx_check_mode_based_ept_exec_controls()
902 if (CC(!page_address_valid(vcpu, vmcs12->vmread_bitmap)) || in nested_vmx_check_shadow_vmcs_controls()
903 CC(!page_address_valid(vcpu, vmcs12->vmwrite_bitmap))) in nested_vmx_check_shadow_vmcs_controls()
913 if (CC(vcpu->arch.apic_base & X2APIC_ENABLE && e->index >> 8 == 0x8)) in nested_vmx_msr_check_common()
915 if (CC(e->index == MSR_IA32_UCODE_WRITE) || /* SDM Table 35-2 */ in nested_vmx_msr_check_common()
916 CC(e->index == MSR_IA32_UCODE_REV)) in nested_vmx_msr_check_common()
918 if (CC(e->reserved != 0)) in nested_vmx_msr_check_common()
926 if (CC(e->index == MSR_FS_BASE) || in nested_vmx_load_msr_check()
927 CC(e->index == MSR_GS_BASE) || in nested_vmx_load_msr_check()
928 CC(e->index == MSR_IA32_SMM_MONITOR_CTL) || /* SMM is not supported */ in nested_vmx_load_msr_check()
937 if (CC(e->index == MSR_IA32_SMBASE) || /* SMM is not supported */ in nested_vmx_store_msr_check()
1142 if (CC(!kvm_vcpu_is_legal_cr3(vcpu, cr3))) { in nested_vmx_load_cr3()
1152 CC(!load_pdptrs(vcpu, cr3))) { in nested_vmx_load_cr3()
2711 if (CC(from_vmentry && !vmx_guest_state_valid(vcpu))) { in prepare_vmcs02()
2765 if (CC(!nested_cpu_has_nmi_exiting(vmcs12) && in nested_vmx_check_nmi_controls()
2769 if (CC(!nested_cpu_has_virtual_nmis(vmcs12) && in nested_vmx_check_nmi_controls()
2783 if (CC(!(vmx->nested.msrs.ept_caps & VMX_EPTP_UC_BIT))) in nested_vmx_check_eptp()
2787 if (CC(!(vmx->nested.msrs.ept_caps & VMX_EPTP_WB_BIT))) in nested_vmx_check_eptp()
2797 if (CC(!(vmx->nested.msrs.ept_caps & VMX_EPT_PAGE_WALK_5_BIT))) in nested_vmx_check_eptp()
2801 if (CC(!(vmx->nested.msrs.ept_caps & VMX_EPT_PAGE_WALK_4_BIT))) in nested_vmx_check_eptp()
2809 if (CC(!kvm_vcpu_is_legal_gpa(vcpu, new_eptp) || ((new_eptp >> 7) & 0x1f))) in nested_vmx_check_eptp()
2814 if (CC(!(vmx->nested.msrs.ept_caps & VMX_EPT_AD_BIT))) in nested_vmx_check_eptp()
2829 if (CC(!vmx_control_verify(vmcs12->pin_based_vm_exec_control, in nested_check_vm_execution_controls()
2832 CC(!vmx_control_verify(vmcs12->cpu_based_vm_exec_control, in nested_check_vm_execution_controls()
2838 CC(!vmx_control_verify(vmcs12->secondary_vm_exec_control, in nested_check_vm_execution_controls()
2843 if (CC(vmcs12->cr3_target_count > nested_cpu_vmx_misc_cr3_count(vcpu)) || in nested_check_vm_execution_controls()
2854 CC(nested_cpu_has_vpid(vmcs12) && !vmcs12->virtual_processor_id)) in nested_check_vm_execution_controls()
2862 CC(!nested_vmx_check_eptp(vcpu, vmcs12->ept_pointer))) in nested_check_vm_execution_controls()
2866 if (CC(vmcs12->vm_function_control & in nested_check_vm_execution_controls()
2871 if (CC(!nested_cpu_has_ept(vmcs12)) || in nested_check_vm_execution_controls()
2872 CC(!page_address_valid(vcpu, vmcs12->eptp_list_address))) in nested_check_vm_execution_controls()
2888 if (CC(!vmx_control_verify(vmcs12->vm_exit_controls, in nested_check_vm_exit_controls()
2891 CC(nested_vmx_check_exit_msr_switch_controls(vcpu, vmcs12))) in nested_check_vm_exit_controls()
2905 if (CC(!vmx_control_verify(vmcs12->vm_entry_controls, in nested_check_vm_entry_controls()
2927 if (CC(intr_type == INTR_TYPE_RESERVED) || in nested_check_vm_entry_controls()
2928 CC(intr_type == INTR_TYPE_OTHER_EVENT && in nested_check_vm_entry_controls()
2933 if (CC(intr_type == INTR_TYPE_NMI_INTR && vector != NMI_VECTOR) || in nested_check_vm_entry_controls()
2934 CC(intr_type == INTR_TYPE_HARD_EXCEPTION && vector > 31) || in nested_check_vm_entry_controls()
2935 CC(intr_type == INTR_TYPE_OTHER_EVENT && vector != 0)) in nested_check_vm_entry_controls()
2942 if (CC(has_error_code != should_have_error_code)) in nested_check_vm_entry_controls()
2946 if (CC(has_error_code && in nested_check_vm_entry_controls()
2951 if (CC(intr_info & INTR_INFO_RESVD_BITS_MASK)) in nested_check_vm_entry_controls()
2959 if (CC(vmcs12->vm_entry_instruction_len > 15) || in nested_check_vm_entry_controls()
2960 CC(vmcs12->vm_entry_instruction_len == 0 && in nested_check_vm_entry_controls()
2961 CC(!nested_cpu_has_zero_length_injection(vcpu)))) in nested_check_vm_entry_controls()
2992 if (CC(!!(vmcs12->vm_exit_controls & VM_EXIT_HOST_ADDR_SPACE_SIZE) != in nested_vmx_check_address_space_size()
3004 if (CC(!nested_host_cr0_valid(vcpu, vmcs12->host_cr0)) || in nested_vmx_check_host_state()
3005 CC(!nested_host_cr4_valid(vcpu, vmcs12->host_cr4)) || in nested_vmx_check_host_state()
3006 CC(!kvm_vcpu_is_legal_cr3(vcpu, vmcs12->host_cr3))) in nested_vmx_check_host_state()
3009 if (CC(is_noncanonical_address(vmcs12->host_ia32_sysenter_esp, vcpu)) || in nested_vmx_check_host_state()
3010 CC(is_noncanonical_address(vmcs12->host_ia32_sysenter_eip, vcpu))) in nested_vmx_check_host_state()
3014 CC(!kvm_pat_valid(vmcs12->host_ia32_pat))) in nested_vmx_check_host_state()
3018 CC(!kvm_valid_perf_global_ctrl(vcpu_to_pmu(vcpu), in nested_vmx_check_host_state()
3023 if (CC(!(vmcs12->host_cr4 & X86_CR4_PAE))) in nested_vmx_check_host_state()
3026 if (CC(vmcs12->vm_entry_controls & VM_ENTRY_IA32E_MODE) || in nested_vmx_check_host_state()
3027 CC(vmcs12->host_cr4 & X86_CR4_PCIDE) || in nested_vmx_check_host_state()
3028 CC((vmcs12->host_rip) >> 32)) in nested_vmx_check_host_state()
3032 if (CC(vmcs12->host_cs_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3033 CC(vmcs12->host_ss_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3034 CC(vmcs12->host_ds_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3035 CC(vmcs12->host_es_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3036 CC(vmcs12->host_fs_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3037 CC(vmcs12->host_gs_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3038 CC(vmcs12->host_tr_selector & (SEGMENT_RPL_MASK | SEGMENT_TI_MASK)) || in nested_vmx_check_host_state()
3039 CC(vmcs12->host_cs_selector == 0) || in nested_vmx_check_host_state()
3040 CC(vmcs12->host_tr_selector == 0) || in nested_vmx_check_host_state()
3041 CC(vmcs12->host_ss_selector == 0 && !ia32e)) in nested_vmx_check_host_state()
3044 if (CC(is_noncanonical_address(vmcs12->host_fs_base, vcpu)) || in nested_vmx_check_host_state()
3045 CC(is_noncanonical_address(vmcs12->host_gs_base, vcpu)) || in nested_vmx_check_host_state()
3046 CC(is_noncanonical_address(vmcs12->host_gdtr_base, vcpu)) || in nested_vmx_check_host_state()
3047 CC(is_noncanonical_address(vmcs12->host_idtr_base, vcpu)) || in nested_vmx_check_host_state()
3048 CC(is_noncanonical_address(vmcs12->host_tr_base, vcpu)) || in nested_vmx_check_host_state()
3049 CC(is_noncanonical_address(vmcs12->host_rip, vcpu))) in nested_vmx_check_host_state()
3059 if (CC(!kvm_valid_efer(vcpu, vmcs12->host_ia32_efer)) || in nested_vmx_check_host_state()
3060 CC(ia32e != !!(vmcs12->host_ia32_efer & EFER_LMA)) || in nested_vmx_check_host_state()
3061 CC(ia32e != !!(vmcs12->host_ia32_efer & EFER_LME))) in nested_vmx_check_host_state()
3078 if (CC(!page_address_valid(vcpu, vmcs12->vmcs_link_pointer))) in nested_vmx_check_vmcs_link_ptr()
3082 CC(kvm_gfn_to_hva_cache_init(vcpu->kvm, ghc, in nested_vmx_check_vmcs_link_ptr()
3086 if (CC(kvm_read_guest_offset_cached(vcpu->kvm, ghc, &hdr, in nested_vmx_check_vmcs_link_ptr()
3091 if (CC(hdr.revision_id != VMCS12_REVISION) || in nested_vmx_check_vmcs_link_ptr()
3092 CC(hdr.shadow_vmcs != nested_cpu_has_shadow_vmcs(vmcs12))) in nested_vmx_check_vmcs_link_ptr()
3103 if (CC(vmcs12->guest_activity_state != GUEST_ACTIVITY_ACTIVE && in nested_check_guest_non_reg_state()
3119 if (CC(!nested_guest_cr0_valid(vcpu, vmcs12->guest_cr0)) || in nested_vmx_check_guest_state()
3120 CC(!nested_guest_cr4_valid(vcpu, vmcs12->guest_cr4))) in nested_vmx_check_guest_state()
3124 CC(!kvm_dr7_valid(vmcs12->guest_dr7))) in nested_vmx_check_guest_state()
3128 CC(!kvm_pat_valid(vmcs12->guest_ia32_pat))) in nested_vmx_check_guest_state()
3137 CC(!kvm_valid_perf_global_ctrl(vcpu_to_pmu(vcpu), in nested_vmx_check_guest_state()
3141 if (CC((vmcs12->guest_cr0 & (X86_CR0_PG | X86_CR0_PE)) == X86_CR0_PG)) in nested_vmx_check_guest_state()
3144 if (CC(ia32e && !(vmcs12->guest_cr4 & X86_CR4_PAE)) || in nested_vmx_check_guest_state()
3145 CC(ia32e && !(vmcs12->guest_cr0 & X86_CR0_PG))) in nested_vmx_check_guest_state()
3159 if (CC(!kvm_valid_efer(vcpu, vmcs12->guest_ia32_efer)) || in nested_vmx_check_guest_state()
3160 CC(ia32e != !!(vmcs12->guest_ia32_efer & EFER_LMA)) || in nested_vmx_check_guest_state()
3161 CC(((vmcs12->guest_cr0 & X86_CR0_PG) && in nested_vmx_check_guest_state()
3167 (CC(is_noncanonical_address(vmcs12->guest_bndcfgs & PAGE_MASK, vcpu)) || in nested_vmx_check_guest_state()
3168 CC((vmcs12->guest_bndcfgs & MSR_IA32_BNDCFGS_RSVD)))) in nested_vmx_check_guest_state()
3298 if (CC(!load_pdptrs(vcpu, vcpu->arch.cr3))) in nested_get_vmcs12_pages()
3664 if (CC(evmptrld_status == EVMPTRLD_VMFAIL)) in nested_vmx_run()
3667 if (CC(!nested_vmx_is_evmptr12_valid(vmx) && in nested_vmx_run()
3679 if (CC(vmcs12->hdr.shadow_vmcs)) in nested_vmx_run()
3702 if (CC(interrupt_shadow & KVM_X86_SHADOW_INT_MOV_SS)) in nested_vmx_run()
3705 if (CC(vmcs12->launch_state == launch)) in nested_vmx_run()