ACPI: Fix logging when no pci_irq is allocated
authorJoe Perches <joe@perches.com>
Wed, 21 Nov 2012 13:46:04 +0000 (13:46 +0000)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 21 Nov 2012 22:56:15 +0000 (23:56 +0100)
Work around a defect in the printk subsystem introduced by a
logging change.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/pci_irq.c

index 0eefa12e648ca67f04aebaaaf0b1f3ade5095662..f2c3d74af23ee8b41cc6ddb1d9409edc3ec0a3bf 100644 (file)
@@ -459,19 +459,19 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
         */
        if (gsi < 0) {
                u32 dev_gsi;
-               dev_warn(&dev->dev, "PCI INT %c: no GSI", pin_name(pin));
                /* Interrupt Line values above 0xF are forbidden */
                if (dev->irq > 0 && (dev->irq <= 0xF) &&
                    (acpi_isa_irq_to_gsi(dev->irq, &dev_gsi) == 0)) {
-                       printk(" - using ISA IRQ %d\n", dev->irq);
+                       dev_warn(&dev->dev, "PCI INT %c: no GSI - using ISA IRQ %d\n",
+                                pin_name(pin), dev->irq);
                        acpi_register_gsi(&dev->dev, dev_gsi,
                                          ACPI_LEVEL_SENSITIVE,
                                          ACPI_ACTIVE_LOW);
-                       return 0;
                } else {
-                       printk("\n");
-                       return 0;
+                       dev_warn(&dev->dev, "PCI INT %c: no GSI\n",
+                                pin_name(pin));
                }
+               return 0;
        }
 
        rc = acpi_register_gsi(&dev->dev, gsi, triggering, polarity);