This reverts commit
b68f1d2e7aa21029d73c7d453a8046e95d351740.
It is causing problems (stuck/stuttering profiling) - when mixed
NMI and non-NMI counters are used.
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: John Kacur <jkacur@redhat.com>
LKML-Reference: <
20090525153931.
703093461@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
return -EACCES;
hwc->nmi = 1;
}
- perf_counters_lapic_init(hwc->nmi);
if (!hwc->irq_period)
hwc->irq_period = x86_pmu.max_period;
hwc->counter_base = x86_pmu.perfctr;
}
+ perf_counters_lapic_init(hwc->nmi);
+
x86_pmu.disable(hwc, idx);
cpuc->counters[idx] = counter;
pr_info("... counter mask: %016Lx\n", perf_counter_mask);
- perf_counters_lapic_init(1);
+ perf_counters_lapic_init(0);
register_die_notifier(&perf_counter_nmi_notifier);
}