x86, perf: Unmask LVTPC only if we have APIC supported
authorCyrill Gorcunov <gorcunov@openvz.org>
Sat, 13 Mar 2010 08:11:16 +0000 (11:11 +0300)
committerIngo Molnar <mingo@elte.hu>
Sat, 13 Mar 2010 12:32:27 +0000 (13:32 +0100)
commit8576e1971663ffdb6139041de97cdd2e1d4791cc
tree9f4a8ec49e65c77fc2f786006bd50844946c9c4a
parent567e54790e5c07152a93b6de4d0210af8b77da87
x86, perf: Unmask LVTPC only if we have APIC supported

Ingo reported:

 |
 | There's a build failure on -tip with the P4 driver, on UP 32-bit, if
 | PERF_EVENTS is enabled but UP_APIC is disabled:
 |
 | arch/x86/built-in.o: In function `p4_pmu_handle_irq':
 | perf_event.c:(.text+0xa756): undefined reference to `apic'
 | perf_event.c:(.text+0xa76e): undefined reference to `apic'
 |

So we have to unmask LVTPC only if we're configured to have one.

Reported-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
CC: Lin Ming <ming.m.lin@intel.com>
CC: Peter Zijlstra <peterz@infradead.org>
LKML-Reference: <20100313081116.GA5179@lenovo>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/cpu/perf_event_p4.c