x86/i8259A: don't open-code LEGACY_VECTOR()
diff mbox series

Message ID 6782ed06-4cfa-279f-2f54-be49f1bc1203@suse.com
State New, archived
Headers show
Series
  • x86/i8259A: don't open-code LEGACY_VECTOR()
Related show

Commit Message

Jan Beulich Dec. 6, 2019, 4:10 p.m. UTC
Signed-off-by: Jan Beulich <jbeulich@suse.com>

Comments

Andrew Cooper Dec. 6, 2019, 4:11 p.m. UTC | #1
On 06/12/2019 16:10, Jan Beulich wrote:
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>

Patch
diff mbox series

--- a/xen/arch/x86/i8259.c
+++ b/xen/arch/x86/i8259.c
@@ -347,9 +347,9 @@  void __init init_IRQ(void)
         if ( irq == 2 ) /* IRQ2 doesn't exist */
             continue;
         desc->handler = &i8259A_irq_type;
-        per_cpu(vector_irq, cpu)[FIRST_LEGACY_VECTOR + irq] = irq;
+        per_cpu(vector_irq, cpu)[LEGACY_VECTOR(irq)] = irq;
         cpumask_copy(desc->arch.cpu_mask, cpumask_of(cpu));
-        desc->arch.vector = FIRST_LEGACY_VECTOR + irq;
+        desc->arch.vector = LEGACY_VECTOR(irq);
     }
     
     per_cpu(vector_irq, cpu)[IRQ0_VECTOR] = 0;