summaryrefslogtreecommitdiffstats
path: root/sys/pci/pci.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>2000-03-19 13:07:12 +0000
committerpeter <peter@FreeBSD.org>2000-03-19 13:07:12 +0000
commit35e00e91c81c202b223a8954e6798bff332b6ca2 (patch)
tree9a22fcf4c02473f470d31db949a7c6d32f882f33 /sys/pci/pci.c
parentd5a5d97386bb5078082d6af0f294010609a96f04 (diff)
downloadFreeBSD-src-35e00e91c81c202b223a8954e6798bff332b6ca2.zip
FreeBSD-src-35e00e91c81c202b223a8954e6798bff332b6ca2.tar.gz
Connect the ISA and PCI compatability shims to an option. In this case
it's options COMPAT_OLDISA and COMPAT_OLDPCI. This is meant to be a fairly strong incentive to update the older drivers to newbus, but doesn't (quite) leave anybody hanging with no hardware support. I was talking with a few folks and I was encouraged to simply break or disable the shims but that was a bit too drastic for my liking.
Diffstat (limited to 'sys/pci/pci.c')
-rw-r--r--sys/pci/pci.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/pci/pci.c b/sys/pci/pci.c
index 74ae9f9..faa813b 100644
--- a/sys/pci/pci.c
+++ b/sys/pci/pci.c
@@ -30,6 +30,7 @@
#include "opt_bus.h"
#include "opt_simos.h"
+#include "opt_compat_oldpci.h"
#include <sys/param.h>
#include <sys/systm.h>
@@ -857,6 +858,9 @@ static struct cdevsw pcicdev = {
#include "pci_if.h"
+static devclass_t pci_devclass;
+
+#ifdef COMPAT_OLDPCI
/*
* A simple driver to wrap the old pci driver mechanism for back-compat.
*/
@@ -919,8 +923,6 @@ static device_method_t pci_compat_methods[] = {
{ 0, 0 }
};
-static devclass_t pci_devclass;
-
/*
* Create a new style driver around each old pci driver.
*/
@@ -950,6 +952,7 @@ compat_pci_handler(module_t mod, int type, void *data)
}
return 0;
}
+#endif
/*
* New style pci driver. Parent device is either a pci-host-bridge or a
OpenPOWER on IntegriCloud