Commit fc26637d authored by Ian Rogers's avatar Ian Rogers Committed by Namhyung Kim
Browse files

perf test: Correct hwmon test PMU detection



Use name to avoid potential other hwmon PMUs.

Signed-off-by: default avatarIan Rogers <irogers@google.com>
Link: https://lore.kernel.org/r/20241118052638.754981-1-irogers@google.com


Signed-off-by: default avatarNamhyung Kim <namhyung@kernel.org>
parent 85c60a01
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -173,7 +173,8 @@ static int do_test(size_t i, bool with_pmu, bool with_alias)
	}

	evlist__for_each_entry(evlist, evsel) {
		if (!perf_pmu__is_hwmon(evsel->pmu))
		if (!evsel->pmu || !evsel->pmu->name ||
		    strcmp(evsel->pmu->name, "hwmon_a_test_hwmon_pmu"))
			continue;

		if (evsel->core.attr.config != (u64)test_events[i].config) {