Re: [PATCH 1/2] perf_counter: cleanup for __perf_event_sched_*()

From: Xiao Guangrong
Date: Thu Sep 24 2009 - 21:23:32 EST




Peter Zijlstra wrote:

>
> Hrm.. I think its not just a cleanup, but an actual bugfix.
>
> The intent was to call event_sched_{in,out}() for single counter groups
> because that's cheaper than group_sched_{in,out}(), however..
>
> - as you noticed, I got the condition wrong, it should have read:
>
> list_empty(&event->sibling_list)
>
> - it failed to call group_can_go_on() which deals with ->exclusive.
>
> - it also doesn't call hw_perf_group_sched_in() which might break
> power.
>

Yeah, I'll fix the title

> Also, I'm not sure I like the comments and WARN_ON bits, the changelog
> should be sufficient.
>

Um, I'll remove the comments and WARN_ON_ONCE()

Thanks,
Xiao
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/