#define pr_fmt(fmt) …
#include <linux/types.h>
#include <linux/kvm_host.h>
#include <linux/perf_event.h>
#include <asm/perf_event.h>
#include "x86.h"
#include "cpuid.h"
#include "lapic.h"
#include "nested.h"
#include "pmu.h"
#define INTEL_RDPMC_GP …
#define INTEL_RDPMC_FIXED …
#define INTEL_RDPMC_TYPE_MASK …
#define INTEL_RDPMC_INDEX_MASK …
#define MSR_PMC_FULL_WIDTH_BIT …
static void reprogram_fixed_counters(struct kvm_pmu *pmu, u64 data)
{ … }
static struct kvm_pmc *intel_rdpmc_ecx_to_pmc(struct kvm_vcpu *vcpu,
unsigned int idx, u64 *mask)
{ … }
static inline u64 vcpu_get_perf_capabilities(struct kvm_vcpu *vcpu)
{ … }
static inline bool fw_writes_is_enabled(struct kvm_vcpu *vcpu)
{ … }
static inline struct kvm_pmc *get_fw_gp_pmc(struct kvm_pmu *pmu, u32 msr)
{ … }
static bool intel_pmu_is_valid_lbr_msr(struct kvm_vcpu *vcpu, u32 index)
{ … }
static bool intel_is_valid_msr(struct kvm_vcpu *vcpu, u32 msr)
{ … }
static struct kvm_pmc *intel_msr_idx_to_pmc(struct kvm_vcpu *vcpu, u32 msr)
{ … }
static inline void intel_pmu_release_guest_lbr_event(struct kvm_vcpu *vcpu)
{ … }
int intel_pmu_create_guest_lbr_event(struct kvm_vcpu *vcpu)
{ … }
static bool intel_pmu_handle_lbr_msrs_access(struct kvm_vcpu *vcpu,
struct msr_data *msr_info, bool read)
{ … }
static int intel_pmu_get_msr(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
{ … }
static int intel_pmu_set_msr(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
{ … }
static __always_inline u64 intel_get_fixed_pmc_eventsel(unsigned int index)
{ … }
static void intel_pmu_enable_fixed_counter_bits(struct kvm_pmu *pmu, u64 bits)
{ … }
static void intel_pmu_refresh(struct kvm_vcpu *vcpu)
{ … }
static void intel_pmu_init(struct kvm_vcpu *vcpu)
{ … }
static void intel_pmu_reset(struct kvm_vcpu *vcpu)
{ … }
static void intel_pmu_legacy_freezing_lbrs_on_pmi(struct kvm_vcpu *vcpu)
{ … }
static void intel_pmu_deliver_pmi(struct kvm_vcpu *vcpu)
{ … }
static void vmx_update_intercept_for_lbr_msrs(struct kvm_vcpu *vcpu, bool set)
{ … }
static inline void vmx_disable_lbr_msrs_passthrough(struct kvm_vcpu *vcpu)
{ … }
static inline void vmx_enable_lbr_msrs_passthrough(struct kvm_vcpu *vcpu)
{ … }
void vmx_passthrough_lbr_msrs(struct kvm_vcpu *vcpu)
{ … }
static void intel_pmu_cleanup(struct kvm_vcpu *vcpu)
{ … }
void intel_pmu_cross_mapped_check(struct kvm_pmu *pmu)
{ … }
struct kvm_pmu_ops intel_pmu_ops __initdata = …;