aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/io_apic_32.c
diff options
context:
space:
mode:
authorYinghai Lu <yhlu.kernel@gmail.com>2008-08-19 23:50:33 -0400
committerIngo Molnar <mingo@elte.hu>2008-10-16 10:52:53 -0400
commitd83e94acd95789829804fd9e442bd18975f4dc89 (patch)
treea7aed9c440365914684b895ece5b43cffcdde70c /arch/x86/kernel/io_apic_32.c
parent7a959cff725872ce9c3a534f10724d7bb2cb3c4a (diff)
x86, io-apic: remove union about dest for log/phy
let user decide the meaning of the bits. This unifies the 32-bit and 64-bit io-apic code a bit. Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/io_apic_32.c')
-rw-r--r--arch/x86/kernel/io_apic_32.c18
1 files changed, 7 insertions, 11 deletions
diff --git a/arch/x86/kernel/io_apic_32.c b/arch/x86/kernel/io_apic_32.c
index 3001924bdd36..353e586822af 100644
--- a/arch/x86/kernel/io_apic_32.c
+++ b/arch/x86/kernel/io_apic_32.c
@@ -1224,7 +1224,7 @@ static int setup_ioapic_entry(int apic, int irq,
1224 1224
1225 entry->delivery_mode = INT_DELIVERY_MODE; 1225 entry->delivery_mode = INT_DELIVERY_MODE;
1226 entry->dest_mode = INT_DEST_MODE; 1226 entry->dest_mode = INT_DEST_MODE;
1227 entry->dest.logical.logical_dest = destination; 1227 entry->dest = destination;
1228 1228
1229 entry->mask = 0; /* enable IRQ */ 1229 entry->mask = 0; /* enable IRQ */
1230 entry->trigger = trigger; 1230 entry->trigger = trigger;
@@ -1336,7 +1336,7 @@ static void __init setup_timer_IRQ0_pin(unsigned int apic, unsigned int pin,
1336 */ 1336 */
1337 entry.dest_mode = INT_DEST_MODE; 1337 entry.dest_mode = INT_DEST_MODE;
1338 entry.mask = 1; /* mask IRQ now */ 1338 entry.mask = 1; /* mask IRQ now */
1339 entry.dest.logical.logical_dest = cpu_mask_to_apicid(TARGET_CPUS); 1339 entry.dest = cpu_mask_to_apicid(TARGET_CPUS);
1340 entry.delivery_mode = INT_DELIVERY_MODE; 1340 entry.delivery_mode = INT_DELIVERY_MODE;
1341 entry.polarity = 0; 1341 entry.polarity = 0;
1342 entry.trigger = 0; 1342 entry.trigger = 0;
@@ -1425,19 +1425,15 @@ __apicdebuginit(void) print_IO_APIC(void)
1425 1425
1426 printk(KERN_DEBUG ".... IRQ redirection table:\n"); 1426 printk(KERN_DEBUG ".... IRQ redirection table:\n");
1427 1427
1428 printk(KERN_DEBUG " NR Log Phy Mask Trig IRR Pol" 1428 printk(KERN_DEBUG " NR Dst Mask Trig IRR Pol"
1429 " Stat Dest Deli Vect: \n"); 1429 " Stat Dmod Deli Vect: \n");
1430 1430
1431 for (i = 0; i <= reg_01.bits.entries; i++) { 1431 for (i = 0; i <= reg_01.bits.entries; i++) {
1432 struct IO_APIC_route_entry entry; 1432 struct IO_APIC_route_entry entry;
1433 1433
1434 entry = ioapic_read_entry(apic, i); 1434 entry = ioapic_read_entry(apic, i);
1435 1435
1436 printk(KERN_DEBUG " %02x %03X %02X ", 1436 printk(KERN_DEBUG " %02x %02X ", i, entry.dest);
1437 i,
1438 entry.dest.logical.logical_dest,
1439 entry.dest.physical.physical_dest
1440 );
1441 1437
1442 printk("%1d %1d %1d %1d %1d %1d %1d %02X\n", 1438 printk("%1d %1d %1d %1d %1d %1d %1d %02X\n",
1443 entry.mask, 1439 entry.mask,
@@ -1717,7 +1713,7 @@ void disable_IO_APIC(void)
1717 entry.dest_mode = 0; /* Physical */ 1713 entry.dest_mode = 0; /* Physical */
1718 entry.delivery_mode = dest_ExtINT; /* ExtInt */ 1714 entry.delivery_mode = dest_ExtINT; /* ExtInt */
1719 entry.vector = 0; 1715 entry.vector = 0;
1720 entry.dest.physical.physical_dest = read_apic_id(); 1716 entry.dest = read_apic_id();
1721 1717
1722 /* 1718 /*
1723 * Add it to the IO-APIC irq-routing table: 1719 * Add it to the IO-APIC irq-routing table:
@@ -2185,7 +2181,7 @@ static inline void __init unlock_ExtINT_logic(void)
2185 2181
2186 entry1.dest_mode = 0; /* physical delivery */ 2182 entry1.dest_mode = 0; /* physical delivery */
2187 entry1.mask = 0; /* unmask IRQ now */ 2183 entry1.mask = 0; /* unmask IRQ now */
2188 entry1.dest.physical.physical_dest = hard_smp_processor_id(); 2184 entry1.dest = hard_smp_processor_id();
2189 entry1.delivery_mode = dest_ExtINT; 2185 entry1.delivery_mode = dest_ExtINT;
2190 entry1.polarity = entry0.polarity; 2186 entry1.polarity = entry0.polarity;
2191 entry1.trigger = 0; 2187 entry1.trigger = 0;