kernel-ark/arch/powerpc
Paul Mackerras c0daaf3f1f perf_counter: powerpc: initialize cpuhw pointer before use
Commit 9e35ad38 ("perf_counter: Rework the perf counter
disable/enable") added code to the powerpc hw_perf_enable (renamed
from hw_perf_restore) to test cpuhw->disabled and return immediately
if it is not set (i.e. if the PMU is already enabled).

Unfortunately the test got added before cpuhw was initialized,
resulting in an oops the first time hw_perf_enable got called.
This fixes it by moving the initialization of cpuhw to before
cpuhw->disabled is tested.

[ Impact: fix oops-causing bug on powerpc ]

Signed-off-by: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
LKML-Reference: <18960.56772.869734.304631@drongo.ozlabs.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2009-05-18 07:38:42 +02:00
..
boot Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc 2009-05-15 08:05:02 -07:00
configs powerpc/8xx: Update defconfigs 2009-05-13 17:29:08 -05:00
include/asm Merge commit 'v2.6.30-rc6' into perfcounters/core 2009-05-18 07:37:49 +02:00
kernel perf_counter: powerpc: initialize cpuhw pointer before use 2009-05-18 07:38:42 +02:00
kvm KVM: ppc: e500: Fix the bug that KVM is unstable in SMP 2009-03-24 11:03:15 +02:00
lib Merge commit 'origin/master' into next 2009-03-11 17:10:07 +11:00
math-emu powerpc/math-emu: Fix efp dependence 2009-03-11 06:00:08 -05:00
mm Merge commit 'v2.6.30-rc6' into perfcounters/core 2009-05-18 07:37:49 +02:00
oprofile powerpc: Fix oprofile sampling of marked events on POWER7 2009-05-15 16:43:41 +10:00
platforms Merge commit 'v2.6.30-rc6' into perfcounters/core 2009-05-18 07:37:49 +02:00
sysdev powerpc/mpic: Fix incorrect allocation of interrupt rev-map 2009-05-15 16:43:41 +10:00
xmon
Kconfig Move dtc and libfdt sources from arch/powerpc/boot to scripts/dtc 2009-05-02 16:52:26 -07:00
Kconfig.debug generic debug pagealloc: build fix 2009-04-02 19:04:48 -07:00
Makefile powerpc/math-emu: Fix efp dependence 2009-03-11 06:00:08 -05:00