git: 037dd0a96771 - main - libpmc: Fix INVERT flag mapping for both Intel and AMD.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 31 May 2022 04:04:47 UTC
The branch main has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=037dd0a9677144a870a381a1bbccbe61e34628dd commit 037dd0a9677144a870a381a1bbccbe61e34628dd Author: Alexander Motin <mav@FreeBSD.org> AuthorDate: 2022-05-31 04:02:06 +0000 Commit: Alexander Motin <mav@FreeBSD.org> CommitDate: 2022-05-31 04:04:43 +0000 libpmc: Fix INVERT flag mapping for both Intel and AMD. Looks like somebody's trivial copy/paste bug. MFC after: 1 month --- lib/libpmc/libpmc_pmu_util.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libpmc/libpmc_pmu_util.c b/lib/libpmc/libpmc_pmu_util.c index 765196ecc8ac..a7c090ceb4d3 100644 --- a/lib/libpmc/libpmc_pmu_util.c +++ b/lib/libpmc/libpmc_pmu_util.c @@ -510,7 +510,7 @@ pmc_pmu_amd_pmcallocate(const char *event_name, struct pmc_op_pmcallocate *pm, if (ped->ped_edge) amd->pm_amd_config |= AMD_PMC_EDGE; if (ped->ped_inv) - amd->pm_amd_config |= AMD_PMC_EDGE; + amd->pm_amd_config |= AMD_PMC_INVERT; if (pm->pm_caps & PMC_CAP_INTERRUPT) amd->pm_amd_config |= AMD_PMC_INT; } @@ -553,7 +553,7 @@ pmc_pmu_intel_pmcallocate(const char *event_name, struct pmc_op_pmcallocate *pm, if (ped->ped_any) iap->pm_iap_config |= IAP_ANY; if (ped->ped_inv) - iap->pm_iap_config |= IAP_EDGE; + iap->pm_iap_config |= IAP_INV; if (pm->pm_caps & PMC_CAP_INTERRUPT) iap->pm_iap_config |= IAP_INT; return (0);