KVM: vmx/pmu: Add PMU_CAP_LBR_FMT check when guest LBR is enabled
[linux-2.6-microblaze.git] / arch / x86 / kvm / vmx / capabilities.h
index 3a18614..da3db1a 100644 (file)
@@ -19,6 +19,7 @@ extern int __read_mostly pt_mode;
 #define PT_MODE_HOST_GUEST     1
 
 #define PMU_CAP_FW_WRITES      (1ULL << 13)
+#define PMU_CAP_LBR_FMT                0x3f
 
 struct nested_vmx_msrs {
        /*
@@ -262,6 +263,12 @@ static inline bool cpu_has_vmx_tsc_scaling(void)
                SECONDARY_EXEC_TSC_SCALING;
 }
 
+static inline bool cpu_has_vmx_bus_lock_detection(void)
+{
+       return vmcs_config.cpu_based_2nd_exec_ctrl &
+           SECONDARY_EXEC_BUS_LOCK_DETECTION;
+}
+
 static inline bool cpu_has_vmx_apicv(void)
 {
        return cpu_has_vmx_apic_register_virt() &&
@@ -378,4 +385,9 @@ static inline u64 vmx_get_perf_capabilities(void)
        return PMU_CAP_FW_WRITES;
 }
 
+static inline u64 vmx_supported_debugctl(void)
+{
+       return 0;
+}
+
 #endif /* __KVM_X86_VMX_CAPS_H */