diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-11-30 16:06:20 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-11-30 16:06:20 -0500 |
commit | 72244c0e68dd664b894adb34a8772a6e4673b4c1 (patch) | |
tree | 5fa5bd9ff7b3d52f9b89898c0f12cfe163b72987 /arch/x86 | |
parent | 93b10052f9146eab4e848b474baf10c2ea22acb3 (diff) | |
parent | 2ed1cdcf9a83205d1343f29b630abff232eaa72c (diff) |
Merge branch 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'irq-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
irq.h: fix missing/extra kernel-doc
genirq: __irq_set_trigger: change pr_warning to pr_debug
irq: fix typo
x86: apic honour irq affinity which was set in early boot
genirq: fix the affinity setting in setup_irq
genirq: keep affinities set from userspace across free/request_irq()
Diffstat (limited to 'arch/x86')
-rw-r--r-- | arch/x86/kernel/io_apic.c | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/arch/x86/kernel/io_apic.c b/arch/x86/kernel/io_apic.c index 1fec0f9b1508..9043251210fb 100644 --- a/arch/x86/kernel/io_apic.c +++ b/arch/x86/kernel/io_apic.c | |||
@@ -3755,7 +3755,9 @@ int acpi_get_override_irq(int bus_irq, int *trigger, int *polarity) | |||
3755 | void __init setup_ioapic_dest(void) | 3755 | void __init setup_ioapic_dest(void) |
3756 | { | 3756 | { |
3757 | int pin, ioapic, irq, irq_entry; | 3757 | int pin, ioapic, irq, irq_entry; |
3758 | struct irq_desc *desc; | ||
3758 | struct irq_cfg *cfg; | 3759 | struct irq_cfg *cfg; |
3760 | cpumask_t mask; | ||
3759 | 3761 | ||
3760 | if (skip_ioapic_setup == 1) | 3762 | if (skip_ioapic_setup == 1) |
3761 | return; | 3763 | return; |
@@ -3772,16 +3774,30 @@ void __init setup_ioapic_dest(void) | |||
3772 | * cpu is online. | 3774 | * cpu is online. |
3773 | */ | 3775 | */ |
3774 | cfg = irq_cfg(irq); | 3776 | cfg = irq_cfg(irq); |
3775 | if (!cfg->vector) | 3777 | if (!cfg->vector) { |
3776 | setup_IO_APIC_irq(ioapic, pin, irq, | 3778 | setup_IO_APIC_irq(ioapic, pin, irq, |
3777 | irq_trigger(irq_entry), | 3779 | irq_trigger(irq_entry), |
3778 | irq_polarity(irq_entry)); | 3780 | irq_polarity(irq_entry)); |
3781 | continue; | ||
3782 | |||
3783 | } | ||
3784 | |||
3785 | /* | ||
3786 | * Honour affinities which have been set in early boot | ||
3787 | */ | ||
3788 | desc = irq_to_desc(irq); | ||
3789 | if (desc->status & | ||
3790 | (IRQ_NO_BALANCING | IRQ_AFFINITY_SET)) | ||
3791 | mask = desc->affinity; | ||
3792 | else | ||
3793 | mask = TARGET_CPUS; | ||
3794 | |||
3779 | #ifdef CONFIG_INTR_REMAP | 3795 | #ifdef CONFIG_INTR_REMAP |
3780 | else if (intr_remapping_enabled) | 3796 | if (intr_remapping_enabled) |
3781 | set_ir_ioapic_affinity_irq(irq, TARGET_CPUS); | 3797 | set_ir_ioapic_affinity_irq(irq, mask); |
3782 | #endif | ||
3783 | else | 3798 | else |
3784 | set_ioapic_affinity_irq(irq, TARGET_CPUS); | 3799 | #endif |
3800 | set_ioapic_affinity_irq(irq, mask); | ||
3785 | } | 3801 | } |
3786 | 3802 | ||
3787 | } | 3803 | } |