aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/apic
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2011-02-05 09:35:51 -0500
committerThomas Gleixner <tglx@linutronix.de>2011-03-12 08:12:00 -0500
commit5451ddc5621550a2f4f82ddeac938b3ca392525f (patch)
treec8ebc8c881ae05265e967b3b230e4ef864544ddc /arch/x86/kernel/apic
parentc60eaf25cd211d2282a6edddb3ce26b1e5795097 (diff)
x86: ioapic: Use irq_data->state
Use the state information in irq_data. That avoids a radix-tree lookup from apic_ack_level() and simplifies setup_ioapic_dest(). Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/apic')
-rw-r--r--arch/x86/kernel/apic/io_apic.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c
index 224edce72b87..e481e00a1b65 100644
--- a/arch/x86/kernel/apic/io_apic.c
+++ b/arch/x86/kernel/apic/io_apic.c
@@ -2431,7 +2431,7 @@ static void ack_apic_level(struct irq_data *data)
2431 irq_complete_move(cfg); 2431 irq_complete_move(cfg);
2432#ifdef CONFIG_GENERIC_PENDING_IRQ 2432#ifdef CONFIG_GENERIC_PENDING_IRQ
2433 /* If we are moving the irq we need to mask it */ 2433 /* If we are moving the irq we need to mask it */
2434 if (unlikely(irq_to_desc(irq)->status & IRQ_MOVE_PENDING)) { 2434 if (unlikely(irqd_is_setaffinity_pending(data))) {
2435 do_unmask_irq = 1; 2435 do_unmask_irq = 1;
2436 mask_ioapic(cfg); 2436 mask_ioapic(cfg);
2437 } 2437 }
@@ -3822,8 +3822,8 @@ int acpi_get_override_irq(u32 gsi, int *trigger, int *polarity)
3822void __init setup_ioapic_dest(void) 3822void __init setup_ioapic_dest(void)
3823{ 3823{
3824 int pin, ioapic, irq, irq_entry; 3824 int pin, ioapic, irq, irq_entry;
3825 struct irq_desc *desc;
3826 const struct cpumask *mask; 3825 const struct cpumask *mask;
3826 struct irq_data *idata;
3827 3827
3828 if (skip_ioapic_setup == 1) 3828 if (skip_ioapic_setup == 1)
3829 return; 3829 return;
@@ -3838,21 +3838,20 @@ void __init setup_ioapic_dest(void)
3838 if ((ioapic > 0) && (irq > 16)) 3838 if ((ioapic > 0) && (irq > 16))
3839 continue; 3839 continue;
3840 3840
3841 desc = irq_to_desc(irq); 3841 idata = irq_get_irq_data(irq);
3842 3842
3843 /* 3843 /*
3844 * Honour affinities which have been set in early boot 3844 * Honour affinities which have been set in early boot
3845 */ 3845 */
3846 if (desc->status & 3846 if (!irqd_can_balance(idata) || irqd_affinity_was_set(idata))
3847 (IRQ_NO_BALANCING | IRQ_AFFINITY_SET)) 3847 mask = idata->affinity;
3848 mask = desc->irq_data.affinity;
3849 else 3848 else
3850 mask = apic->target_cpus(); 3849 mask = apic->target_cpus();
3851 3850
3852 if (intr_remapping_enabled) 3851 if (intr_remapping_enabled)
3853 ir_ioapic_set_affinity(&desc->irq_data, mask, false); 3852 ir_ioapic_set_affinity(idata, mask, false);
3854 else 3853 else
3855 ioapic_set_affinity(&desc->irq_data, mask, false); 3854 ioapic_set_affinity(idata, mask, false);
3856 } 3855 }
3857 3856
3858} 3857}