summaryrefslogtreecommitdiff
path: root/arch/x86/kernel/genapic_flat_64.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-01-28 05:13:04 +0100
committerIngo Molnar <mingo@elte.hu>2009-01-28 23:20:18 +0100
commit0b06e734bff7554c31eac4aad2fc9be4adb7c1c1 (patch)
tree52b3f9ccf6d85e503cf949c888ded6722c66e3a3 /arch/x86/kernel/genapic_flat_64.c
parent08125d3edab90644724652eedec3e219e3e0f2e7 (diff)
x86: clean up the APIC_DEST_LOGICAL logic
Impact: cleanup The bigsmp and es7000 subarchitectures un-defined APIC_DEST_LOGICAL in a rather nasty way by re-defining it to zero. That is infinitely fragile and makes it very hard to see what to code really does in a given context. The very same constant has different meanings and values - depending on which subarch is enabled. Untangle this mess by never undefining the constant, but instead propagating the right values into the genapic driver templates. Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/genapic_flat_64.c')
-rw-r--r--arch/x86/kernel/genapic_flat_64.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/x86/kernel/genapic_flat_64.c b/arch/x86/kernel/genapic_flat_64.c
index d437a60cc589..fd242c6b3ba1 100644
--- a/arch/x86/kernel/genapic_flat_64.c
+++ b/arch/x86/kernel/genapic_flat_64.c
@@ -74,7 +74,7 @@ static inline void _flat_send_IPI_mask(unsigned long mask, int vector)
unsigned long flags;
local_irq_save(flags);
- __send_IPI_dest_field(mask, vector, APIC_DEST_LOGICAL);
+ __send_IPI_dest_field(mask, vector, apic->apic_destination_logical);
local_irq_restore(flags);
}
@@ -114,7 +114,7 @@ static void flat_send_IPI_allbutself(int vector)
_flat_send_IPI_mask(mask, vector);
}
} else if (num_online_cpus() > 1) {
- __send_IPI_shortcut(APIC_DEST_ALLBUT, vector,APIC_DEST_LOGICAL);
+ __send_IPI_shortcut(APIC_DEST_ALLBUT, vector, apic->apic_destination_logical);
}
}
@@ -123,7 +123,7 @@ static void flat_send_IPI_all(int vector)
if (vector == NMI_VECTOR)
flat_send_IPI_mask(cpu_online_mask, vector);
else
- __send_IPI_shortcut(APIC_DEST_ALLINC, vector, APIC_DEST_LOGICAL);
+ __send_IPI_shortcut(APIC_DEST_ALLINC, vector, apic->apic_destination_logical);
}
static unsigned int get_apic_id(unsigned long x)
@@ -181,11 +181,11 @@ struct genapic apic_flat = {
.apic_id_registered = flat_apic_id_registered,
.irq_delivery_mode = dest_LowestPrio,
- .irq_dest_mode = (APIC_DEST_LOGICAL != 0),
+ .irq_dest_mode = 1, /* logical */
.target_cpus = flat_target_cpus,
.disable_esr = 0,
- .apic_destination_logical = 0,
+ .apic_destination_logical = APIC_DEST_LOGICAL,
.check_apicid_used = NULL,
.check_apicid_present = NULL,
@@ -327,7 +327,7 @@ struct genapic apic_physflat = {
.apic_id_registered = flat_apic_id_registered,
.irq_delivery_mode = dest_Fixed,
- .irq_dest_mode = (APIC_DEST_PHYSICAL != 0),
+ .irq_dest_mode = 0, /* physical */
.target_cpus = physflat_target_cpus,
.disable_esr = 0,