]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
x86/pci/intel_mid_pci: Use proper constants for irq polarity
authorThomas Gleixner <tglx@linutronix.de>
Wed, 29 Jul 2015 19:16:19 +0000 (21:16 +0200)
committerThomas Gleixner <tglx@linutronix.de>
Wed, 29 Jul 2015 19:23:50 +0000 (21:23 +0200)
polarity = 0 means active high. Not really intuitive, so people add
comments to it instead of just using a self explaining constant.

Use the IOAPIC_POL_ constants and get rid of those horrible to read
tail comments.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>
arch/x86/pci/intel_mid_pci.c

index b096da5237945c3e550ad5d5b9a541b4a230fe18..8b93e634af84c4698e6f7c6ab718a018e2cdc9db 100644 (file)
@@ -220,7 +220,7 @@ static int intel_mid_pci_irq_enable(struct pci_dev *dev)
 
        switch (intel_mid_identify_cpu()) {
        case INTEL_MID_CPU_CHIP_TANGIER:
-               polarity = 0; /* active high */
+               polarity = IOAPIC_POL_HIGH;
 
                /* Special treatment for IRQ0 */
                if (dev->irq == 0) {
@@ -235,7 +235,7 @@ static int intel_mid_pci_irq_enable(struct pci_dev *dev)
                }
                break;
        default:
-               polarity = 1; /* active low */
+               polarity = IOAPIC_POL_LOW;
                break;
        }