diff --git a/kernel/events/core.c b/kernel/events/core.c index 5200b608b4818a7a80887a5127dc276b96200ce0..e82e70025d4233ea67cbb9b3ae280f759896ba09 100644 --- a/kernel/events/core.c +++ b/kernel/events/core.c @@ -4388,7 +4388,8 @@ static void perf_output_read_group(struct perf_output_handle *handle, list_for_each_entry(sub, &leader->sibling_list, group_entry) { n = 0; - if (sub != event) + if ((sub != event) && + (sub->state == PERF_EVENT_STATE_ACTIVE)) sub->pmu->read(sub); values[n++] = perf_event_count(sub);