Re: PCI device problem - MMCONFIG, cannot allocate resource region,resource collisions

From: Wayne Sherman
Date: Thu May 24 2007 - 20:27:30 EST


Ivan Kokshaysky wrote:
Actually, it should be something like this (also untested).

Ivan.

--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
@@ -1690,6 +1690,14 @@ static void __devinit quirk_p64h2_1k_io(struct pci_dev *dev)
}
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x1460, quirk_p64h2_1k_io);
+/* Give unknown D-Link network adapters a proper class */
+static void __devinit quirk_dlink_unknown(struct pci_dev *dev)
+{
+ if ((dev->class >> 8) == PCI_CLASS_NOT_DEFINED)
+ dev->class = PCI_CLASS_NETWORK_ETHERNET << 8;
+}
+DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_DLINK, 0x4901, quirk_dlink_unknown);

Ivan,

I tried a couple variations of the patch above. It got me further, but I still wasn't getting the base address assigned properly. I suspected a bad card, so I tried another one I have here. It is likely that I have been fighting with bad hardware all this time. The other card has a known device ID, a proper class code, and does not give resource allocation errors. I have an e-mail into D-Link to inquire about the buggy card.

I appreciate both yours and Jesse's help to troubleshoot this problem.

Best Regards,

Wayne Sherman

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/