summaryrefslogtreecommitdiff
path: root/arch/x86/machine/pmu_amd.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/machine/pmu_amd.c')
-rw-r--r--arch/x86/machine/pmu_amd.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/x86/machine/pmu_amd.c b/arch/x86/machine/pmu_amd.c
index 0f8b14a..1c6545e 100644
--- a/arch/x86/machine/pmu_amd.c
+++ b/arch/x86/machine/pmu_amd.c
@@ -197,6 +197,12 @@ pmu_amd_read(unsigned int pmc_id)
return cpu_get_msr64(PMU_AMD_MSR_PERCTR0 + pmc_id);
}
+static uint8_t
+pmu_amd_get_pmc_width(void)
+{
+ return PMU_AMD_PMC_WIDTH;
+}
+
static int __init
pmu_amd_setup(void)
{
@@ -225,6 +231,7 @@ pmu_amd_setup(void)
pmu_driver.start = pmu_amd_start;
pmu_driver.stop = pmu_amd_stop;
pmu_driver.read = pmu_amd_read;
+ pmu_driver.get_pmc_width = pmu_amd_get_pmc_width;
return perfmon_pmu_register(&pmu_driver);
}