On Tue, Jan 24, 2017 at 05:41:22PM +0100, Peter Zijlstra wrote:

SNIP

> ---
> diff --git a/arch/x86/events/core.c b/arch/x86/events/core.c
> index 1635c0c8df23..a95707a4140f 100644
> --- a/arch/x86/events/core.c
> +++ b/arch/x86/events/core.c
> @@ -1343,6 +1343,8 @@ void x86_pmu_stop(struct perf_event *event, int flags)
>               cpuc->events[hwc->idx] = NULL;
>               WARN_ON_ONCE(hwc->state & PERF_HES_STOPPED);
>               hwc->state |= PERF_HES_STOPPED;
> +     } else {
> +             hwc->state |= PERF_HES_ARCH;
>       }
>  
>       if ((flags & PERF_EF_UPDATE) && !(hwc->state & PERF_HES_UPTODATE)) {

I think that will work, I'll try to test it

jirka

Reply via email to