Re: [PATCH] x86,perf: Unmask LVTPC only if we have APIC supported

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Cyrill Gorcunov
Date: Saturday, March 13, 2010 - 6:42 am

On Sat, Mar 13, 2010 at 01:40:36PM +0100, Ingo Molnar wrote:

Looking at code a bit and config deps I think the former proposal with
#ifdef is minimal (in amount of changes) and sufficient. perf_event.c
uses #ifdef CONFIG_X86_LOCAL_APIC for the very same reason.

The former issue with config dependencies is that we may need to compile
perf_event.c without CONFIG_LOCAL_APIC support at all (and this is a case
for which you've posted the config). CONFIG_LOCAL_APIC deps on X86_UP_APIC,
the config has no X86_UP_APIC support and as result -- no CONFIG_LOCAL_APIC and
no apic.o compiled.

So, as expected, no apic_write/read and friends there. We may introduce
apic_write/read weak(s) but this would only mess the code more and would
smell unpleasant I think :) .

All-in-once: unresolved external symbol here, which could be fixed either
by introducing dummy symbol, or conditional compilation. I think the second
is preferred if the issue is just one line code.

Or you mean something different and I took a wrong mind-path?

	-- Cyrill
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH] x86,perf: Unmask LVTPC only if we have APIC su ..., Cyrill Gorcunov, (Sat Mar 13, 6:42 am)
[tip:perf/core] x86, perf: Unmask LVTPC only if we have AP ..., tip-bot for Cyrill G ..., (Sat Mar 13, 9:21 am)