File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 2929#define ARCH_PERFMON_EVENTSEL_INV (1ULL << 23)
3030#define ARCH_PERFMON_EVENTSEL_CMASK 0xFF000000ULL
3131
32- #define AMD_PERFMON_EVENTSEL_GUESTONLY (1ULL << 40)
33- #define AMD_PERFMON_EVENTSEL_HOSTONLY (1ULL << 41)
32+ #define AMD64_EVENTSEL_GUESTONLY (1ULL << 40)
33+ #define AMD64_EVENTSEL_HOSTONLY (1ULL << 41)
3434
3535#define AMD64_EVENTSEL_EVENT \
3636 (ARCH_PERFMON_EVENTSEL_EVENT | (0x0FULL << 32))
Original file line number Diff line number Diff line change @@ -156,9 +156,9 @@ static int amd_pmu_hw_config(struct perf_event *event)
156156 event -> hw .config &= ~(ARCH_PERFMON_EVENTSEL_USR |
157157 ARCH_PERFMON_EVENTSEL_OS );
158158 else if (event -> attr .exclude_host )
159- event -> hw .config |= AMD_PERFMON_EVENTSEL_GUESTONLY ;
159+ event -> hw .config |= AMD64_EVENTSEL_GUESTONLY ;
160160 else if (event -> attr .exclude_guest )
161- event -> hw .config |= AMD_PERFMON_EVENTSEL_HOSTONLY ;
161+ event -> hw .config |= AMD64_EVENTSEL_HOSTONLY ;
162162
163163 if (event -> attr .type != PERF_TYPE_RAW )
164164 return 0 ;
@@ -336,7 +336,7 @@ static void amd_pmu_cpu_starting(int cpu)
336336 struct amd_nb * nb ;
337337 int i , nb_id ;
338338
339- cpuc -> perf_ctr_virt_mask = AMD_PERFMON_EVENTSEL_HOSTONLY ;
339+ cpuc -> perf_ctr_virt_mask = AMD64_EVENTSEL_HOSTONLY ;
340340
341341 if (boot_cpu_data .x86_max_cores < 2 )
342342 return ;
@@ -669,7 +669,7 @@ void amd_pmu_disable_virt(void)
669669 * SVM is disabled the Guest-only bits still gets set and the counter
670670 * will not count anything.
671671 */
672- cpuc -> perf_ctr_virt_mask = AMD_PERFMON_EVENTSEL_HOSTONLY ;
672+ cpuc -> perf_ctr_virt_mask = AMD64_EVENTSEL_HOSTONLY ;
673673
674674 /* Reload all events */
675675 x86_pmu_disable_all ();
You can’t perform that action at this time.
0 commit comments