Re: [PATCH] fix tlan.c for !PCI
From: Jeff Garzik
Date: Sat May 15 2004 - 13:55:01 EST
Linux Kernel Mailing List wrote:
ChangeSet 1.1691, 2004/05/15 10:23:43-07:00, akpm@xxxxxxxx
[PATCH] fix tlan.c for !PCI
From: Adrian Bunk <bunk@xxxxxxxxx>
drivers/net/tlan.c: In function `tlan_remove_one':
drivers/net/tlan.c:449: warning: implicit declaration of function `pci_release_regions'
# This patch includes the following deltas:
# ChangeSet 1.1690 -> 1.1691
# drivers/net/tlan.c 1.31 -> 1.32
#
tlan.c | 4 ++++
1 files changed, 4 insertions(+)
diff -Nru a/drivers/net/tlan.c b/drivers/net/tlan.c
--- a/drivers/net/tlan.c Sat May 15 11:23:50 2004
+++ b/drivers/net/tlan.c Sat May 15 11:23:50 2004
@@ -446,7 +446,9 @@
pci_free_consistent(priv->pciDev, priv->dmaSize, priv->dmaStorage, priv->dmaStorageDMA );
}
+#ifdef CONFIG_PCI
pci_release_regions(pdev);
+#endif
Ug. Please revert and fix it the right way.
Think about this one: we are getting the warning inside a function that
will only ever be called when CONFIG_PCI is defined, the PCI ->remove hook.
IMO one of two things needs to happen:
a) wrap the PCI probe functions in tlan.c with CONFIG_PCI
or
b) create the proper wrapper in include/linux/pci.h, following
established practice in that header
-
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/