11921f3aaSLike Xu /* SPDX-License-Identifier: GPL-2.0 */ 21921f3aaSLike Xu #if !defined(KVM_X86_PMU_OP) || !defined(KVM_X86_PMU_OP_OPTIONAL) 31921f3aaSLike Xu BUILD_BUG_ON(1) 41921f3aaSLike Xu #endif 51921f3aaSLike Xu 61921f3aaSLike Xu /* 71921f3aaSLike Xu * KVM_X86_PMU_OP() and KVM_X86_PMU_OP_OPTIONAL() are used to help generate 81921f3aaSLike Xu * both DECLARE/DEFINE_STATIC_CALL() invocations and 91921f3aaSLike Xu * "static_call_update()" calls. 101921f3aaSLike Xu * 111921f3aaSLike Xu * KVM_X86_PMU_OP_OPTIONAL() can be used for those functions that can have 121921f3aaSLike Xu * a NULL definition, for example if "static_call_cond()" will be used 131921f3aaSLike Xu * at the call sites. 141921f3aaSLike Xu */ 157aadaa98SLike Xu KVM_X86_PMU_OP(hw_event_available) 161921f3aaSLike Xu KVM_X86_PMU_OP(pmc_idx_to_pmc) 171921f3aaSLike Xu KVM_X86_PMU_OP(rdpmc_ecx_to_pmc) 181921f3aaSLike Xu KVM_X86_PMU_OP(msr_idx_to_pmc) 191921f3aaSLike Xu KVM_X86_PMU_OP(is_valid_rdpmc_ecx) 201921f3aaSLike Xu KVM_X86_PMU_OP(is_valid_msr) 211921f3aaSLike Xu KVM_X86_PMU_OP(get_msr) 221921f3aaSLike Xu KVM_X86_PMU_OP(set_msr) 231921f3aaSLike Xu KVM_X86_PMU_OP(refresh) 241921f3aaSLike Xu KVM_X86_PMU_OP(init) 25*57bbd59aSSean Christopherson KVM_X86_PMU_OP_OPTIONAL(reset) 261921f3aaSLike Xu KVM_X86_PMU_OP_OPTIONAL(deliver_pmi) 271921f3aaSLike Xu KVM_X86_PMU_OP_OPTIONAL(cleanup) 281921f3aaSLike Xu 291921f3aaSLike Xu #undef KVM_X86_PMU_OP 301921f3aaSLike Xu #undef KVM_X86_PMU_OP_OPTIONAL 31