diff --git a/src/util/virperf.c b/src/util/virperf.c index f64692bf39c49ec9edacbd40e8411ec3a898ebed..4493608a0f16e5e66119408905b5f50be8efb015 100644 --- a/src/util/virperf.c +++ b/src/util/virperf.c @@ -198,6 +198,9 @@ virPerfEventEnable(virPerfPtr perf, if (!event || !event_attr) return -1; + if (event->enabled) + return 0; + if (event_attr->attrType == 0 && (type == VIR_PERF_EVENT_CMT || type == VIR_PERF_EVENT_MBMT || type == VIR_PERF_EVENT_MBML)) {