]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
IB/ipath: Print better error messages if kernel is misconfigured
authorBryan O'Sullivan <bryan.osullivan@qlogic.com>
Thu, 15 Mar 2007 21:45:06 +0000 (14:45 -0700)
committerRoland Dreier <rolandd@cisco.com>
Thu, 19 Apr 2007 03:20:58 +0000 (20:20 -0700)
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/hw/ipath/ipath_driver.c

index ab7458e904c3cb2acdf6264fad4fa8365043a574..056e10663289b8ac1c34c21e0c4842c5bfb37445 100644 (file)
@@ -390,15 +390,23 @@ static int __devinit ipath_init_one(struct pci_dev *pdev,
 
        /* setup the chip-specific functions, as early as possible. */
        switch (ent->device) {
-#ifdef CONFIG_HT_IRQ
        case PCI_DEVICE_ID_INFINIPATH_HT:
+#ifdef CONFIG_HT_IRQ
                ipath_init_iba6110_funcs(dd);
                break;
+#else
+               ipath_dev_err(dd, "QLogic HT device 0x%x cannot work if "
+                             "CONFIG_HT_IRQ is not enabled\n", ent->device);
+               return -ENODEV;
 #endif
-#ifdef CONFIG_PCI_MSI
        case PCI_DEVICE_ID_INFINIPATH_PE800:
+#ifdef CONFIG_PCI_MSI
                ipath_init_iba6120_funcs(dd);
                break;
+#else
+               ipath_dev_err(dd, "QLogic PCIE device 0x%x cannot work if "
+                             "CONFIG_PCI_MSI is not enabled\n", ent->device);
+               return -ENODEV;
 #endif
        default:
                ipath_dev_err(dd, "Found unknown QLogic deviceid 0x%x, "